openapi: 3.0.3
info:
  title: 'Academy of mine APIs'
  description: 'List of all API endpoints'
  version: 1.0.0
servers:
  -
    url: 'https://demo.aomlms.com'
paths:
  /api/users/customRegistrationFields:
    get:
      summary: 'Retrieve Custom User Fields that needs to be shown on the Registration page'
      operationId: retrieveCustomUserFieldsThatNeedsToBeShownOnTheRegistrationPage
      description: 'Retrieves the details of pre saved Custom User Fields.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  fields:
                    user_meta_key_1:
                      id: 1
                      type: text
                      label: Gender
                      defaultValue: null
                      isRequired: false
                      optionLabel: []
                      isFieldOnRegistrationPage: false
                      isFieldOnCertificate: true
                      includeInReportExports:
                        - export-users
                        - export-orders
                    user_meta_key_2:
                      id: 2
                      type: textarea
                      label: 'What is your home address'
                      defaultValue: null
                      isRequired: true
                      optionLabel: []
                      isFieldOnRegistrationPage: true
                      isFieldOnCertificate: false
                      includeInReportExports: []
                properties:
                  fields:
                    type: object
                    properties:
                      user_meta_key_1:
                        type: object
                        properties:
                          id:
                            type: integer
                            example: 1
                          type:
                            type: string
                            example: text
                          label:
                            type: string
                            example: Gender
                          defaultValue:
                            type: string
                            example: null
                          isRequired:
                            type: boolean
                            example: false
                          optionLabel:
                            type: array
                            example: []
                          isFieldOnRegistrationPage:
                            type: boolean
                            example: false
                          isFieldOnCertificate:
                            type: boolean
                            example: true
                          includeInReportExports:
                            type: array
                            example:
                              - export-users
                              - export-orders
                            items:
                              type: string
                      user_meta_key_2:
                        type: object
                        properties:
                          id:
                            type: integer
                            example: 2
                          type:
                            type: string
                            example: textarea
                          label:
                            type: string
                            example: 'What is your home address'
                          defaultValue:
                            type: string
                            example: null
                          isRequired:
                            type: boolean
                            example: true
                          optionLabel:
                            type: array
                            example: []
                          isFieldOnRegistrationPage:
                            type: boolean
                            example: true
                          isFieldOnCertificate:
                            type: boolean
                            example: false
                          includeInReportExports:
                            type: array
                            example: []
      tags:
        - Users
      security: []
  /api/users/update-webinar-status:
    get:
      summary: 'Update the status of a webinar registration for the given user and course.'
      operationId: updateTheStatusOfAWebinarRegistrationForTheGivenUserAndCourse
      description: ''
      parameters:
        -
          in: query
          name: ids
          description: 'array The IDs of the course registrations to update.'
          example: '[101, 102, 103]'
          required: true
          schema:
            type: string
            description: 'array The IDs of the course registrations to update.'
            example: '[101, 102, 103]'
        -
          in: query
          name: status
          description: 'string The new status of the webinar registration.'
          example: '"approved"'
          required: true
          schema:
            type: string
            description: 'string The new status of the webinar registration.'
            example: '"approved"'
        -
          in: query
          name: webinarId
          description: 'int The ID of the webinar module.'
          example: '55'
          required: true
          schema:
            type: string
            description: 'int The ID of the webinar module.'
            example: '55'
        -
          in: query
          name: portalId
          description: 'int The ID of the portal.'
          example: '12'
          required: true
          schema:
            type: string
            description: 'int The ID of the portal.'
            example: '12'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Status Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Status Updated Successfully'
      tags:
        - Users
      security: []
  /api/users/update-webinar-notes:
    get:
      summary: 'Update the notes for a webinar registration for the given user and course.'
      operationId: updateTheNotesForAWebinarRegistrationForTheGivenUserAndCourse
      description: ''
      parameters:
        -
          in: query
          name: ids
          description: 'array The IDs of the course registrations to update.'
          example: '[101, 102, 103]'
          required: true
          schema:
            type: string
            description: 'array The IDs of the course registrations to update.'
            example: '[101, 102, 103]'
        -
          in: query
          name: webinarId
          description: 'int The ID of the webinar module.'
          example: '55'
          required: true
          schema:
            type: string
            description: 'int The ID of the webinar module.'
            example: '55'
        -
          in: query
          name: portalId
          description: 'int The ID of the portal.'
          example: '12'
          required: true
          schema:
            type: string
            description: 'int The ID of the portal.'
            example: '12'
        -
          in: query
          name: notes
          description: 'string The new notes of the webinar registration.'
          example: '"This is a test note"'
          required: true
          schema:
            type: string
            description: 'string The new notes of the webinar registration.'
            example: '"This is a test note"'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Notes Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Notes Updated Successfully'
      tags:
        - Users
      security: []
  /api/user/reports/student-quizzes:
    get:
      summary: 'Get the quizzes for a given user and portal.'
      operationId: getTheQuizzesForAGivenUserAndPortal
      description: ''
      parameters:
        -
          in: query
          name: user_id
          description: 'int The ID of the user.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'int The ID of the user.'
            example: '1'
        -
          in: query
          name: searchPortalIds
          description: 'array The IDs of the portals to search in.'
          example: '[1,2]'
          required: true
          schema:
            type: string
            description: 'array The IDs of the portals to search in.'
            example: '[1,2]'
        -
          in: query
          name: page_number
          description: 'int The page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'int The page number.'
            example: '1'
        -
          in: query
          name: page_size
          description: 'int The page size.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'int The page size.'
            example: '10'
        -
          in: query
          name: order_by
          description: 'object The order by parameters.'
          example: '{"colName":"registered_on","direction":"desc"}'
          required: true
          schema:
            type: string
            description: 'object The order by parameters.'
            example: '{"colName":"registered_on","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'object The search parameters.'
          example: '{"nameOrEmail":"John Doe","status":[]}'
          required: true
          schema:
            type: string
            description: 'object The search parameters.'
            example: '{"nameOrEmail":"John Doe","status":[]}'
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n \"totalNotStarted\": 2,\n \"totalInProgress\": 1,\n \"totalCompleted\": 1,\n \"recordsTotal\": 4,\n \"recordsFiltered\": 4,\n \"records\": Array,\n \"userDetails\": Object\n}"
      tags:
        - Users
      security: []
  /api/user/portals:
    get:
      summary: 'Retrieves a list of portals for a given user.'
      operationId: retrievesAListOfPortalsForAGivenUser
      description: ''
      parameters:
        -
          in: query
          name: userId
          description: 'optional User ID to filter portals.'
          example: '1'
          required: false
          schema:
            type: string
            description: 'optional User ID to filter portals.'
            example: '1'
        -
          in: query
          name: type
          description: 'optional The type of user to filter portals.'
          example: checkout
          required: false
          schema:
            type: string
            description: 'optional The type of user to filter portals.'
            example: checkout
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  portals:
                    -
                      id: 1
                      name: 'Portal 1'
                      referralCode: portal1
                      userType: portal_admin
                      totalSeat: 100
                      subscriptionId: 1
                      parentPortalId: 1
                      slug: portal-1
                    -
                      id: 2
                      name: 'Portal 2'
                      referralCode: portal2
                      userType: portal_admin
                      totalSeat: 50
                      subscriptionId: 2
                      parentPortalId: 2
                      slug: portal-2
                  siteLogo: 'http://example.com/logo.jpg'
                  baseUrl: 'http://example.com'
                properties:
                  portals:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Portal 1'
                        referralCode: portal1
                        userType: portal_admin
                        totalSeat: 100
                        subscriptionId: 1
                        parentPortalId: 1
                        slug: portal-1
                      -
                        id: 2
                        name: 'Portal 2'
                        referralCode: portal2
                        userType: portal_admin
                        totalSeat: 50
                        subscriptionId: 2
                        parentPortalId: 2
                        slug: portal-2
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Portal 1'
                        referralCode:
                          type: string
                          example: portal1
                        userType:
                          type: string
                          example: portal_admin
                        totalSeat:
                          type: integer
                          example: 100
                        subscriptionId:
                          type: integer
                          example: 1
                        parentPortalId:
                          type: integer
                          example: 1
                        slug:
                          type: string
                          example: portal-1
                  siteLogo:
                    type: string
                    example: 'http://example.com/logo.jpg'
                  baseUrl:
                    type: string
                    example: 'http://example.com'
      tags:
        - Users
      security: []
  /api/userType/lookup:
    get:
      summary: 'User Types'
      operationId: userTypes
      description: 'Retrieves all the user types in the system like admin, owner, staff, general.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: admin
                    display_name: Admin
                  -
                    db_value: owner
                    display_name: Owner
                  -
                    db_value: staff
                    display_name: Staff
                  -
                    db_value: general
                    display_name: General
      tags:
        - Users
      security: []
  /api/users/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the users in a tabular list format with pagination mode.\nYou can apply filter using search_param via nameOrEmail, membershipId, userCategoryId."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the users you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the users you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on nameOrEmail, membershipId, userCategoryId.'
          example: '{"nameOrEmail":"John Doe","membershipId":1, "userCategoryId":1}'
          required: false
          schema:
            type: string
            description: 'for searching items based on nameOrEmail, membershipId, userCategoryId.'
            example: '{"nameOrEmail":"John Doe","membershipId":1, "userCategoryId":1}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 4
                      first_name: John
                      last_name: Doe
                      is_disabled: false
                      email: john@example.com
                      avatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#03A9F4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">JD</text></svg>'
                      display_type: General
                      created_at: 'Aug 06, 2020 07:20 AM'
                      last_login: '2 days ago'
                      source: default
                      portals: 'Portal 1, Portal 2'
                      user_category: 'Category 1, Category 2'
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 4
                        first_name: John
                        last_name: Doe
                        is_disabled: false
                        email: john@example.com
                        avatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#03A9F4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">JD</text></svg>'
                        display_type: General
                        created_at: 'Aug 06, 2020 07:20 AM'
                        last_login: '2 days ago'
                        source: default
                        portals: 'Portal 1, Portal 2'
                        user_category: 'Category 1, Category 2'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 4
                        first_name:
                          type: string
                          example: John
                        last_name:
                          type: string
                          example: Doe
                        is_disabled:
                          type: boolean
                          example: false
                        email:
                          type: string
                          example: john@example.com
                        avatar:
                          type: string
                          example: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#03A9F4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">JD</text></svg>'
                        display_type:
                          type: string
                          example: General
                        created_at:
                          type: string
                          example: 'Aug 06, 2020 07:20 AM'
                        last_login:
                          type: string
                          example: '2 days ago'
                        source:
                          type: string
                          example: default
                        portals:
                          type: string
                          example: 'Portal 1, Portal 2'
                        user_category:
                          type: string
                          example: 'Category 1, Category 2'
      tags:
        - Users
      security: []
  /api/users/getUsersByType:
    get:
      summary: 'Retrieve Users By Type'
      operationId: retrieveUsersByType
      description: 'Retrieves a list of users filtered by user type and optionally by portal ID.'
      parameters:
        -
          in: query
          name: userType
          description: 'The type of user to filter by.'
          example: learner
          required: false
          schema:
            type: string
            description: 'The type of user to filter by.'
            example: learner
        -
          in: query
          name: portalId
          description: 'Optional. The ID of the portal to filter users by.'
          example: '1'
          required: false
          schema:
            type: string
            description: 'Optional. The ID of the portal to filter users by.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  records:
                    -
                      id: 1
                      name: 'John Doe (john@example.com)'
                properties:
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'John Doe (john@example.com)'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'John Doe (john@example.com)'
      tags:
        - Users
      security: []
  /api/users/enableEnrollContent:
    get:
      summary: 'Enables enroll content for a user.'
      operationId: enablesEnrollContentForAUser
      description: ''
      parameters:
        -
          in: query
          name: userId
          description: 'int The ID of the user to enable enroll content for.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'int The ID of the user to enable enroll content for.'
            example: '1'
        -
          in: query
          name: selectedCourseView
          description: 'string The view to enable for courses.'
          example: "'grid'"
          required: true
          schema:
            type: string
            description: 'string The view to enable for courses.'
            example: "'grid'"
        -
          in: query
          name: selectedLearningPathView
          description: 'string The view to enable for learning paths.'
          example: "'list'"
          required: true
          schema:
            type: string
            description: 'string The view to enable for learning paths.'
            example: "'list'"
        -
          in: query
          name: selectedCourseViewMode
          description: 'string The mode to enable for courses.'
          example: "'enroll'"
          required: true
          schema:
            type: string
            description: 'string The mode to enable for courses.'
            example: "'enroll'"
        -
          in: query
          name: selectedLearningPathViewMode
          description: 'string The mode to enable for learning paths.'
          example: "'enroll'"
          required: true
          schema:
            type: string
            description: 'string The mode to enable for learning paths.'
            example: "'enroll'"
        -
          in: query
          name: type
          description: "string The type of content to enable. Must be either 'course' or 'learningPath'."
          example: "'course'"
          required: true
          schema:
            type: string
            description: "string The type of content to enable. Must be either 'course' or 'learningPath'."
            example: "'course'"
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Setting Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Setting Updated Successfully'
      tags:
        - Users
      security: []
  /api/users/lookup:
    get:
      summary: 'Retrieve Users'
      operationId: retrieveUsers
      description: 'Retrieves a list of users filtered by search term and optionally by portal ID and user type.'
      parameters:
        -
          in: query
          name: search_term
          description: 'The search term to search for users.'
          example: John
          required: true
          schema:
            type: string
            description: 'The search term to search for users.'
            example: John
        -
          in: query
          name: portalId
          description: 'optional The ID of the portal to filter users by.'
          example: '1'
          required: false
          schema:
            type: string
            description: 'optional The ID of the portal to filter users by.'
            example: '1'
        -
          in: query
          name: userType
          description: 'optional The type of user to filter by.'
          example: learner
          required: false
          schema:
            type: string
            description: 'optional The type of user to filter by.'
            example: learner
        -
          in: query
          name: remote_user_search
          description: 'optional Set to true to search for users globally. Set to false to search within the portal and its sub-portals.'
          example: qui
          required: false
          schema:
            type: string
            description: 'optional Set to true to search for users globally. Set to false to search within the portal and its sub-portals.'
            example: qui
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  records:
                    -
                      id: 1
                      full_name: 'John Doe'
                      email: john@example.com
                      user_type: learner
                properties:
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        full_name: 'John Doe'
                        email: john@example.com
                        user_type: learner
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        full_name:
                          type: string
                          example: 'John Doe'
                        email:
                          type: string
                          example: john@example.com
                        user_type:
                          type: string
                          example: learner
      tags:
        - Users
      security: []
  /api/user/create:
    post:
      summary: 'Creates a new user.'
      operationId: createsANewUser
      description: ''
      parameters:
        -
          in: query
          name: firstName
          description: 'First name of the user.'
          example: John
          required: true
          schema:
            type: string
            description: 'First name of the user.'
            example: John
        -
          in: query
          name: lastName
          description: 'Last name of the user.'
          example: Doe
          required: true
          schema:
            type: string
            description: 'Last name of the user.'
            example: Doe
        -
          in: query
          name: email
          description: 'Email of the user.'
          example: john.doe@example.com
          required: true
          schema:
            type: string
            description: 'Email of the user.'
            example: john.doe@example.com
        -
          in: query
          name: password
          description: 'Password for the user. Must be at least 8 characters long and should not have been compromised according to the haveibeenpwned.com API.'
          example: 'h\*{P/tCM8u'
          required: true
          schema:
            type: string
            description: 'Password for the user. Must be at least 8 characters long and should not have been compromised according to the haveibeenpwned.com API.'
            example: 'h\*{P/tCM8u'
        -
          in: query
          name: userCategory
          description: 'optional Array of category IDs or names to assign to the user.'
          example: '[1,2,3]'
          required: false
          schema:
            type: string
            description: 'optional Array of category IDs or names to assign to the user.'
            example: '[1,2,3]'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'User created successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'User created successfully'
      tags:
        - Users
      security: []
  /api/user/bulkUpload:
    post:
      summary: 'Bulk upload users from csv file'
      operationId: bulkUploadUsersFromCsvFile
      description: ''
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'User(s) uploaded successfully'
                  is_success: 'true'
                properties:
                  message:
                    type: string
                    example: 'User(s) uploaded successfully'
                  is_success:
                    type: string
                    example: 'true'
      tags:
        - Users
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                userList:
                  type: array
                  description: 'The list of user objects containing email, first_name, last_name, password, and other custom fields'
                  example:
                    - amet
                  items:
                    type: string
                selectedCourses:
                  type: array
                  description: 'List of Course Ids to be enrolled'
                  example:
                    - officia
                  items:
                    type: string
                selectedLearningPaths:
                  type: array
                  description: 'List of Learning Path Ids to be enrolled'
                  example:
                    - dolorum
                  items:
                    type: string
                membershipId:
                  type: integer
                  description: 'Membership Id to be attached'
                  example: 2
                portalId:
                  type: integer
                  description: 'Portal Id to be attached'
                  example: 1
              required:
                - userList
                - selectedCourses
                - selectedLearningPaths
                - membershipId
                - portalId
      security: []
  /api/user/saved-cards:
    get:
      summary: 'Retrieves the saved cards for a user.'
      operationId: retrievesTheSavedCardsForAUser
      description: ''
      parameters:
        -
          in: query
          name: userId
          description: 'int The ID of the user to retrieve saved cards for.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'int The ID of the user to retrieve saved cards for.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 101
                    last4: '4242'
                    payment_gateway_name: Stripe
                    card_type: Visa
                  -
                    id: 102
                    last4: '1881'
                    payment_gateway_name: PayPal
                    card_type: Mastercard
      tags:
        - Users
      security: []
  /api/user/delete-card:
    post:
      summary: 'Deletes a saved card for a user.'
      operationId: deletesASavedCardForAUser
      description: ''
      parameters:
        -
          in: query
          name: paymentTokenId
          description: 'int The ID of the payment token to delete.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'int The ID of the payment token to delete.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: success
                  message: 'Card has been deleted.'
                properties:
                  status:
                    type: string
                    example: success
                  message:
                    type: string
                    example: 'Card has been deleted.'
        400:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n \"status\": \"error\",\n \"message\": \"Card not deleted. Please try again later.\" OR \"Card cannot be deleted as it is linked to an active subscription.\"\n}"
      tags:
        - Users
      security: []
  /api/user/getBulkUploadSampleFile:
    get:
      summary: 'Returns a sample file in JSON format which can be downloaded by the user and used as a template for bulk uploading users.'
      operationId: returnsASampleFileInJSONFormatWhichCanBeDownloadedByTheUserAndUsedAsATemplateForBulkUploadingUsers
      description: "The sample file contains dummy data for the standard fields and the custom user fields that have been set up in the system.\nThe dummy data is in a format that can be easily copied and pasted into the user's own CSV file.\nThe first record in the sample file contains data for all the fields, while the subsequent records contain blank data.\nThis is to make it easy for the user to see what data is required for each field."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  headers:
                    - email
                    - first_name
                    - last_name
                    - password
                    - custom_field_1
                    - custom_field_2
                    - custom_field_3
                  records:
                    -
                      email: fakeemail1@aom.com
                      first_name: 'Fake FName1'
                      last_name: 'Fake LName1'
                      password: Qwerty@123
                      custom_field_1: 'Fake Custom Field 1 Value'
                      custom_field_2: 'Fake Custom Field 2 Value'
                      custom_field_3: 'Fake Custom Field 3 Value'
                    -
                      email: fakeemail2@aom.com
                      first_name: 'Fake FName2'
                      last_name: 'Fake LName2'
                      password: ''
                      custom_field_1: ''
                      custom_field_2: ''
                      custom_field_3: ''
                    -
                      email: fakeemail3@aom.com
                      first_name: 'Fake FName3'
                      last_name: 'Fake LName3'
                      password: ''
                      custom_field_1: ''
                      custom_field_2: ''
                      custom_field_3: ''
                properties:
                  headers:
                    type: array
                    example:
                      - email
                      - first_name
                      - last_name
                      - password
                      - custom_field_1
                      - custom_field_2
                      - custom_field_3
                    items:
                      type: string
                  records:
                    type: array
                    example:
                      -
                        email: fakeemail1@aom.com
                        first_name: 'Fake FName1'
                        last_name: 'Fake LName1'
                        password: Qwerty@123
                        custom_field_1: 'Fake Custom Field 1 Value'
                        custom_field_2: 'Fake Custom Field 2 Value'
                        custom_field_3: 'Fake Custom Field 3 Value'
                      -
                        email: fakeemail2@aom.com
                        first_name: 'Fake FName2'
                        last_name: 'Fake LName2'
                        password: ''
                        custom_field_1: ''
                        custom_field_2: ''
                        custom_field_3: ''
                      -
                        email: fakeemail3@aom.com
                        first_name: 'Fake FName3'
                        last_name: 'Fake LName3'
                        password: ''
                        custom_field_1: ''
                        custom_field_2: ''
                        custom_field_3: ''
                    items:
                      type: object
                      properties:
                        email:
                          type: string
                          example: fakeemail1@aom.com
                        first_name:
                          type: string
                          example: 'Fake FName1'
                        last_name:
                          type: string
                          example: 'Fake LName1'
                        password:
                          type: string
                          example: Qwerty@123
                        custom_field_1:
                          type: string
                          example: 'Fake Custom Field 1 Value'
                        custom_field_2:
                          type: string
                          example: 'Fake Custom Field 2 Value'
                        custom_field_3:
                          type: string
                          example: 'Fake Custom Field 3 Value'
      tags:
        - Users
      security: []
  /api/user/getBlockedEmailsAndDomains:
    get:
      summary: 'Get blocked and allowed emails and domains for a given portal.'
      operationId: getBlockedAndAllowedEmailsAndDomainsForAGivenPortal
      description: ''
      parameters:
        -
          in: query
          name: portalId
          description: 'The ID of the portal to get the blocked and allowed emails and domains for. If not provided, will return the blocked emails and domains for the main site.'
          example: 1
          required: false
          schema:
            type: integer
            description: 'The ID of the portal to get the blocked and allowed emails and domains for. If not provided, will return the blocked emails and domains for the main site.'
            example: 1
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  blocked:
                    - blocked1@example.com
                    - blocked2@example.com
                  allowed:
                    - allowed1@example.com
                    - allowed2@example.com
                properties:
                  blocked:
                    type: array
                    example:
                      - blocked1@example.com
                      - blocked2@example.com
                    items:
                      type: string
                  allowed:
                    type: array
                    example:
                      - allowed1@example.com
                      - allowed2@example.com
                    items:
                      type: string
      tags:
        - Users
      security: []
  '/api/user/{id}':
    get:
      summary: 'Retrieve User By ID'
      operationId: retrieveUserByID
      description: 'This endpoint returns the user details based on the ID specified.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  firstName: John
                  lastName: Doe
                  email: john@aom.com
                  lastLoggedIn: '2 hours ago'
                  avatar: '<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><circle cx="50" cy="50" r="50" stroke="background" stroke-width="0" fill="#03A9F4" /><text x="50" y="50" font-size="40" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">JD</text></svg>'
                  disabled: false
                  userType: staff
                  currentLoggedUserType: owner
                  membership:
                    id: 1
                    name: Silver
                    expiryDate: null
                  customUserMetas:
                    full_name:
                      type: text
                      label: 'Full Name'
                      submitted_value: 'John Doe'
                      placeholder_value: ''
                    user_type:
                      type: dropdown
                      label: 'User Type'
                      submitted_value: 1
                      placeholder_value: ''
                      option_label:
                        - Staff
                        - Owner
                      option_value:
                        - 1
                        - 2
                  internal_note: null
                properties:
                  id:
                    type: integer
                    example: 1
                  firstName:
                    type: string
                    example: John
                  lastName:
                    type: string
                    example: Doe
                  email:
                    type: string
                    example: john@aom.com
                  lastLoggedIn:
                    type: string
                    example: '2 hours ago'
                  avatar:
                    type: string
                    example: '<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><circle cx="50" cy="50" r="50" stroke="background" stroke-width="0" fill="#03A9F4" /><text x="50" y="50" font-size="40" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">JD</text></svg>'
                  disabled:
                    type: boolean
                    example: false
                  userType:
                    type: string
                    example: staff
                  currentLoggedUserType:
                    type: string
                    example: owner
                  membership:
                    type: object
                    properties:
                      id:
                        type: integer
                        example: 1
                      name:
                        type: string
                        example: Silver
                      expiryDate:
                        type: string
                        example: null
                  customUserMetas:
                    type: object
                    properties:
                      full_name:
                        type: object
                        properties:
                          type:
                            type: string
                            example: text
                          label:
                            type: string
                            example: 'Full Name'
                          submitted_value:
                            type: string
                            example: 'John Doe'
                          placeholder_value:
                            type: string
                            example: ''
                      user_type:
                        type: object
                        properties:
                          type:
                            type: string
                            example: dropdown
                          label:
                            type: string
                            example: 'User Type'
                          submitted_value:
                            type: integer
                            example: 1
                          placeholder_value:
                            type: string
                            example: ''
                          option_label:
                            type: array
                            example:
                              - Staff
                              - Owner
                            items:
                              type: string
                          option_value:
                            type: array
                            example:
                              - 1
                              - 2
                            items:
                              type: integer
                  internal_note:
                    type: string
                    example: null
      tags:
        - Users
      security: []
    put:
      summary: 'Updates an existing user.'
      operationId: updatesAnExistingUser
      description: ''
      parameters:
        -
          in: query
          name: id
          description: 'User ID to update.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'User ID to update.'
            example: '1'
        -
          in: query
          name: firstName
          description: 'First name of the user.'
          example: John
          required: true
          schema:
            type: string
            description: 'First name of the user.'
            example: John
        -
          in: query
          name: lastName
          description: 'Last name of the user.'
          example: Doe
          required: true
          schema:
            type: string
            description: 'Last name of the user.'
            example: Doe
        -
          in: query
          name: email
          description: 'Email of the user.'
          example: john.doe@example.com
          required: true
          schema:
            type: string
            description: 'Email of the user.'
            example: john.doe@example.com
        -
          in: query
          name: disabled
          description: 'boolean whether the user is disabled or not.'
          example: '0'
          required: true
          schema:
            type: string
            description: 'boolean whether the user is disabled or not.'
            example: '0'
        -
          in: query
          name: internal_note
          description: 'optional Internal note for the user.'
          example: 'This is a note.'
          required: false
          schema:
            type: string
            description: 'optional Internal note for the user.'
            example: 'This is a note.'
        -
          in: query
          name: customUserMetas
          description: 'optional Custom user meta fields.'
          example: '{"meta_key1":{"type":"text","submitted_value":"value1"},"meta_key2":{"type":"checkbox","submitted_value":[1,2,3]}}'
          required: false
          schema:
            type: string
            description: 'optional Custom user meta fields.'
            example: '{"meta_key1":{"type":"text","submitted_value":"value1"},"meta_key2":{"type":"checkbox","submitted_value":[1,2,3]}}'
        -
          in: query
          name: userCategory
          description: 'optional Array of category IDs or names to assign to the user.'
          example: '[1,2,3]'
          required: false
          schema:
            type: string
            description: 'optional Array of category IDs or names to assign to the user.'
            example: '[1,2,3]'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'User updated successfully'
                properties:
                  message:
                    type: string
                    example: 'User updated successfully'
      tags:
        - Users
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the user.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/user/{id}/update-membership':
    put:
      summary: 'Update Membership'
      operationId: updateMembership
      description: "Updates the membership of a specified user. The membership will be revoked if the expired_at date is in the past.\nIf the expired_at is not provided, the expired_at of the membership will be used."
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: 'array A response with a message. Example: {message: User updated successfully}'
      tags:
        - Users
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'The ID of the membership.'
                  example: '1'
                expired_at:
                  type: nullable
                  description: 'The expired date for the user.'
                  example: "'2021-10-03 23:59:59'"
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the user.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/user/updatePassword/{id}':
    put:
      summary: 'Updates the password of a user.'
      operationId: updatesThePasswordOfAUser
      description: ''
      parameters:
        -
          in: query
          name: password
          description: 'New password for the user. Must be at least 8 characters long and should not have been compromised according to the haveibeenpwned.com API.'
          example: '"MyP@ssw0rd"'
          required: true
          schema:
            type: string
            description: 'New password for the user. Must be at least 8 characters long and should not have been compromised according to the haveibeenpwned.com API.'
            example: '"MyP@ssw0rd"'
        -
          in: query
          name: userId
          description: 'ID of the user to update the password for.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the user to update the password for.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Password updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Password updated successfully'
      tags:
        - Users
      security: []
  /api/users/enrolled-courses:
    get:
      summary: 'Enrolled Courses'
      operationId: enrolledCourses
      description: 'Retrieves all courses enrolled by a specified user. The response includes course status, completion percentage, last access date, and access status.'
      parameters:
        -
          in: query
          name: user_id
          description: 'ID of the user to retrieve enrolled courses for.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the user to retrieve enrolled courses for.'
            example: '1'
        -
          in: query
          name: page_size
          description: 'Number of records to return per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'Number of records to return per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'optional Returns results in some order.'
          example: '{"colName":"created_at","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'optional Returns results in some order.'
            example: '{"colName":"created_at","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'optional Search parameters related to course.'
          example: '{"status":["Not Started","In Progress"],"nameOrEmail":"John Doe"}'
          required: false
          schema:
            type: string
            description: 'optional Search parameters related to course.'
            example: '{"status":["Not Started","In Progress"],"nameOrEmail":"John Doe"}'
        -
          in: query
          name: portalId
          description: 'ID of the portal to filter courses by portal and sub-portals. Use -1 to skip portal filtering.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the portal to filter courses by portal and sub-portals. Use -1 to skip portal filtering.'
            example: '1'
        -
          in: query
          name: viewType
          description: '"self" or "manage". If "self", then only the enrolled courses of the requesting user are returned. If "manage", then all enrolled courses of users managed by the requesting user are returned.'
          example: '"self"'
          required: true
          schema:
            type: string
            description: '"self" or "manage". If "self", then only the enrolled courses of the requesting user are returned. If "manage", then all enrolled courses of users managed by the requesting user are returned.'
            example: '"self"'
        -
          in: query
          name: manage_course
          description: 'true or false. If true, then only courses with access type "manage" are returned. If false, then all courses are returned.'
          example: 'true'
          required: true
          schema:
            type: string
            description: 'true or false. If true, then only courses with access type "manage" are returned. If false, then all courses are returned.'
            example: 'true'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 50
                  recordsFiltered: 50
                  records:
                    -
                      id: 1
                      courseId: 1
                      featuredImageUrl: 'https://example.com/course1.jpg'
                      courseSlug: course1
                      courseName: 'Course 1'
                      lastAccessed: '2 days ago'
                      status: 'Not Started'
                      display_status: 'Not Started'
                      accessStatus: Allowed
                      percentComplete: 0
                      courseStatus: publish
                      registered_on: 'Aug 09, 2020'
                      started_on: ''
                      completed_on: ''
                      expire_on: Never
                      isExpired: false
                      canRecertify: false
                      estimatedCompletionTime: '2 hours'
                      certificate_count: 0
                      enableCourseRating: true
                      rating: 4.5
                  name: 'John Doe'
                  email: john@example.com
                  userType: learner
                  avatar: 'https://example.com/avatar.jpg'
                  isLearner: true
                properties:
                  recordsTotal:
                    type: integer
                    example: 50
                  recordsFiltered:
                    type: integer
                    example: 50
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        courseId: 1
                        featuredImageUrl: 'https://example.com/course1.jpg'
                        courseSlug: course1
                        courseName: 'Course 1'
                        lastAccessed: '2 days ago'
                        status: 'Not Started'
                        display_status: 'Not Started'
                        accessStatus: Allowed
                        percentComplete: 0
                        courseStatus: publish
                        registered_on: 'Aug 09, 2020'
                        started_on: ''
                        completed_on: ''
                        expire_on: Never
                        isExpired: false
                        canRecertify: false
                        estimatedCompletionTime: '2 hours'
                        certificate_count: 0
                        enableCourseRating: true
                        rating: 4.5
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        courseId:
                          type: integer
                          example: 1
                        featuredImageUrl:
                          type: string
                          example: 'https://example.com/course1.jpg'
                        courseSlug:
                          type: string
                          example: course1
                        courseName:
                          type: string
                          example: 'Course 1'
                        lastAccessed:
                          type: string
                          example: '2 days ago'
                        status:
                          type: string
                          example: 'Not Started'
                        display_status:
                          type: string
                          example: 'Not Started'
                        accessStatus:
                          type: string
                          example: Allowed
                        percentComplete:
                          type: integer
                          example: 0
                        courseStatus:
                          type: string
                          example: publish
                        registered_on:
                          type: string
                          example: 'Aug 09, 2020'
                        started_on:
                          type: string
                          example: ''
                        completed_on:
                          type: string
                          example: ''
                        expire_on:
                          type: string
                          example: Never
                        isExpired:
                          type: boolean
                          example: false
                        canRecertify:
                          type: boolean
                          example: false
                        estimatedCompletionTime:
                          type: string
                          example: '2 hours'
                        certificate_count:
                          type: integer
                          example: 0
                        enableCourseRating:
                          type: boolean
                          example: true
                        rating:
                          type: number
                          example: 4.5
                  name:
                    type: string
                    example: 'John Doe'
                  email:
                    type: string
                    example: john@example.com
                  userType:
                    type: string
                    example: learner
                  avatar:
                    type: string
                    example: 'https://example.com/avatar.jpg'
                  isLearner:
                    type: boolean
                    example: true
      tags:
        - Users
      security: []
  /api/users/getPortalCourses:
    get:
      summary: 'Get courses enrolled by a user in a particular portal'
      operationId: getCoursesEnrolledByAUserInAParticularPortal
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  courses:
                    -
                      courseId: 1
                      registrationId: 1
                      type: course
                      contentName: 'Course 1'
                      rating: 4.5
                      enableCourseRating: true
                      featureImage: 'https://example.com/image.jpg'
                      launchUrl: /portal/course/course-1/launch
                      canRecertify: true
                      isEnrolled: true
                      lastAccessed: '3 days ago'
                      display_status: 'In Progress'
                      percentComplete: 20
                      isExpired: false
                      registered_on: '2021-01-01 00:00:00'
                      estimatedCompletionTime: '3 hours'
                      status: 'In Progress'
                  totalRecords: 10
                  recordsFiltered: 10
                properties:
                  courses:
                    type: array
                    example:
                      -
                        courseId: 1
                        registrationId: 1
                        type: course
                        contentName: 'Course 1'
                        rating: 4.5
                        enableCourseRating: true
                        featureImage: 'https://example.com/image.jpg'
                        launchUrl: /portal/course/course-1/launch
                        canRecertify: true
                        isEnrolled: true
                        lastAccessed: '3 days ago'
                        display_status: 'In Progress'
                        percentComplete: 20
                        isExpired: false
                        registered_on: '2021-01-01 00:00:00'
                        estimatedCompletionTime: '3 hours'
                        status: 'In Progress'
                    items:
                      type: object
                      properties:
                        courseId:
                          type: integer
                          example: 1
                        registrationId:
                          type: integer
                          example: 1
                        type:
                          type: string
                          example: course
                        contentName:
                          type: string
                          example: 'Course 1'
                        rating:
                          type: number
                          example: 4.5
                        enableCourseRating:
                          type: boolean
                          example: true
                        featureImage:
                          type: string
                          example: 'https://example.com/image.jpg'
                        launchUrl:
                          type: string
                          example: /portal/course/course-1/launch
                        canRecertify:
                          type: boolean
                          example: true
                        isEnrolled:
                          type: boolean
                          example: true
                        lastAccessed:
                          type: string
                          example: '3 days ago'
                        display_status:
                          type: string
                          example: 'In Progress'
                        percentComplete:
                          type: integer
                          example: 20
                        isExpired:
                          type: boolean
                          example: false
                        registered_on:
                          type: string
                          example: '2021-01-01 00:00:00'
                        estimatedCompletionTime:
                          type: string
                          example: '3 hours'
                        status:
                          type: string
                          example: 'In Progress'
                  totalRecords:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
      tags:
        - Users
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'The ID of the portal'
                  example: 7
                page_size:
                  type: integer
                  description: 'The number of records per page'
                  example: 17
                page_number:
                  type: integer
                  description: 'The page number'
                  example: 18
                order_by:
                  type: object
                  description: 'The order by object with colName and direction properties'
                  example: []
                  properties: {  }
                search_param:
                  type: object
                  description: 'The search object with name, categories, and status properties'
                  example: []
                  properties: {  }
              required:
                - portalId
                - page_size
                - page_number
                - order_by
                - search_param
      security: []
  /api/user/delete:
    post:
      summary: 'Delete a user or multiple users'
      operationId: deleteAUserOrMultipleUsers
      description: "Deletes a specified user or multiple users in a single API call.\nSupports deleting users with or without enrollments.\nDoes not delete users who have created courses or modules.\nDoes not delete users who have portal access.\nAlso deletes announcements, cart abandonment records, and user reviews associated with the user."
      parameters:
        -
          in: query
          name: delete_ids
          description: 'JSON string containing the IDs of the users to be deleted.'
          example: '"[1,2,3]"'
          required: true
          schema:
            type: string
            description: 'JSON string containing the IDs of the users to be deleted.'
            example: '"[1,2,3]"'
        -
          in: query
          name: user_id
          description: 'optional ID of the user. Defaults to the authenticated user if not provided.'
          example: 4
          required: false
          schema:
            type: integer
            description: 'optional ID of the user. Defaults to the authenticated user if not provided.'
            example: 4
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: string
                  deletedStudents:
                    -
                      id: 2
                      name: 'John Doe'
                    -
                      id: 3
                      name: 'Jane Doe'
                  notDeletedStudents:
                    -
                      id: 1
                      name: 'Adam Smith'
                  usedInCourses:
                    'John Doe':
                      -
                        id: 1
                        name: 'Course 1'
                      -
                        id: 2
                        name: 'Course 2'
                  usedAsCourseAuthors:
                    'John Doe':
                      -
                        id: 1
                        name: 'Course 1'
                      -
                        id: 2
                        name: 'Course 2'
                  usedAsModuleAuthors:
                    'John Doe':
                      -
                        id: 1
                        name: 'Module 1'
                      -
                        id: 2
                        name: 'Module 2'
                  usedInPortals:
                    'John Doe':
                      -
                        id: 1
                        name: 'Portal 1'
                      -
                        id: 2
                        name: 'Portal 2'
                properties:
                  message:
                    type: string
                    example: string
                  deletedStudents:
                    type: array
                    example:
                      -
                        id: 2
                        name: 'John Doe'
                      -
                        id: 3
                        name: 'Jane Doe'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 2
                        name:
                          type: string
                          example: 'John Doe'
                  notDeletedStudents:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Adam Smith'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Adam Smith'
                  usedInCourses:
                    type: object
                    properties:
                      'John Doe':
                        type: array
                        example:
                          -
                            id: 1
                            name: 'Course 1'
                          -
                            id: 2
                            name: 'Course 2'
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 1
                            name:
                              type: string
                              example: 'Course 1'
                  usedAsCourseAuthors:
                    type: object
                    properties:
                      'John Doe':
                        type: array
                        example:
                          -
                            id: 1
                            name: 'Course 1'
                          -
                            id: 2
                            name: 'Course 2'
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 1
                            name:
                              type: string
                              example: 'Course 1'
                  usedAsModuleAuthors:
                    type: object
                    properties:
                      'John Doe':
                        type: array
                        example:
                          -
                            id: 1
                            name: 'Module 1'
                          -
                            id: 2
                            name: 'Module 2'
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 1
                            name:
                              type: string
                              example: 'Module 1'
                  usedInPortals:
                    type: object
                    properties:
                      'John Doe':
                        type: array
                        example:
                          -
                            id: 1
                            name: 'Portal 1'
                          -
                            id: 2
                            name: 'Portal 2'
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 1
                            name:
                              type: string
                              example: 'Portal 1'
      tags:
        - Users
      security: []
  /api/user/quickEdit:
    post:
      summary: 'Quick Edit'
      operationId: quickEdit
      description: "Updates user details in bulk based on the provided parameters. This function supports enabling/disabling users,\nenrolling users in courses and learning paths, and attaching users to memberships."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Users updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Users updated Successfully'
      tags:
        - Users
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                user_ids:
                  type: array
                  description: 'IDs of the users to be updated.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                course_ids:
                  type: array
                  description: 'Optional. IDs of the courses to enroll users in.'
                  example:
                    - 10
                    - 20
                  items:
                    type: string
                disabled:
                  type: boolean
                  description: 'Optional. Whether to disable the users.'
                  example: true
                learning_path_ids:
                  type: array
                  description: 'Optional. IDs of the learning paths to enroll users in.'
                  example:
                    - 5
                    - 6
                  items:
                    type: string
                enrollMembershipId:
                  type: integer
                  description: 'Optional. ID of the membership to attach users to.'
                  example: 2
                portalId:
                  type: integer
                  description: 'Optional. ID of the portal for membership attachment.'
                  example: 1
              required:
                - user_ids
      security: []
  '/api/user/{id}/addAddress':
    post:
      summary: 'Insert Address'
      operationId: insertAddress
      description: "Adds a new address for a specified user with the provided details.\nIf the address is marked as default, it updates other addresses of the same type to not be default."
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Address added successfully'
                properties:
                  message:
                    type: string
                    example: 'Address added successfully'
      tags:
        - Users
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                fullName:
                  type: string
                  description: 'Full Name of the user.'
                  example: 'John Doe'
                orgName:
                  type: string
                  description: 'optional Organization Name.'
                  example: 'Acme Corp'
                orgVatId:
                  type: string
                  description: 'optional Organization VAT ID.'
                  example: VAT12345
                addressLine1:
                  type: string
                  description: 'Address line1 of the user.'
                  example: 'Boring Street'
                addressLine2:
                  type: string
                  description: 'optional Address line2 of the user.'
                  example: 'Awesome Colony'
                zipcode:
                  type: string
                  description: 'Zipcode of the user address.'
                  example: '123456'
                city:
                  type: string
                  description: 'City of the user address.'
                  example: Mumbai
                state:
                  type: string
                  description: 'optional State of the user address.'
                  example: NY
                country:
                  type: string
                  description: 'Country of the user address.'
                  example: US
                isDefault:
                  type: boolean
                  description: 'Is the address default for billing.'
                  example: true
                userId:
                  type: integer
                  description: 'ID of the user for whom the address is being added.'
                  example: 4
                type:
                  type: string
                  description: 'Type of address.'
                  example: billing
                billing_address_id:
                  type: integer
                  description: 'optional Billing address ID if applicable.'
                  example: 5
              required:
                - fullName
                - addressLine1
                - zipcode
                - city
                - country
                - isDefault
                - userId
                - type
      security: []
  '/api/user/userAddress/{id}':
    get:
      summary: 'Retrieve all billing addresses of a user'
      operationId: retrieveAllBillingAddressesOfAUser
      description: 'Retrieves all the billing addresses which are added by the specified user.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    isDefault: false
                    fullName: 'John Doe'
                    addressLine1: 'Boring Street'
                    addressLine2: 'Awesome Colony'
                    zipcode: '123456'
                    city: Mumbai
                    state: MH
                    country: IN
      tags:
        - Users
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the user address row from UsersAddress Model.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/user/userShippingAddress/{id}':
    get:
      summary: 'Get shipping address By ID.'
      operationId: getShippingAddressByID
      description: 'Retrieves a list of all shipping addresses associated with a specific user ID.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    isDefault: true
                    fullName: 'John Doe'
                    orgName: 'Acme Inc.'
                    orgVatId: VAT123456
                    addressLine1: '123 Main St'
                    addressLine2: 'Suite 456'
                    zipcode: '12345'
                    city: 'New York'
                    state: NY
                    country: USA
      tags:
        - Users
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the user.'
        example: 12
        required: true
        schema:
          type: integer
  /api/user/dashboard/statistics:
    get:
      summary: 'Retrieve User Dashboard Statistics'
      operationId: retrieveUserDashboardStatistics
      description: "Returns user's dashboard statistics which includes Total Courses, Completed Courses, In Progress Courses, Not Started Courses, and Time Spent."
      parameters:
        -
          in: query
          name: user_id
          description: 'ID of the user.'
          example: '4'
          required: true
          schema:
            type: string
            description: 'ID of the user.'
            example: '4'
        -
          in: query
          name: portalId
          description: 'ID of the portal.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the portal.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  totalCourses: 10
                  completedCourses: 2
                  inProgressCourses: 3
                  notStartedCourses: 5
                  timeSpent: 12
                properties:
                  totalCourses:
                    type: integer
                    example: 10
                  completedCourses:
                    type: integer
                    example: 2
                  inProgressCourses:
                    type: integer
                    example: 3
                  notStartedCourses:
                    type: integer
                    example: 5
                  timeSpent:
                    type: integer
                    example: 12
      tags:
        - Users
      security: []
  /api/user-activities:
    get:
      summary: 'Retrieve User Activities'
      operationId: retrieveUserActivities
      description: "Returns all activities performed by a specified user in a paginated format.\nSupports filtering, sorting, and context-based queries."
      parameters:
        -
          in: query
          name: user_id
          description: 'ID of the user. Defaults to the authenticated user if not provided.'
          example: 4
          required: true
          schema:
            type: integer
            description: 'ID of the user. Defaults to the authenticated user if not provided.'
            example: 4
        -
          in: query
          name: page_size
          description: 'Number of records per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'Number of records per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'Current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'Current page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'optional JSON string to specify the column and direction for ordering.'
          example: '{"colName":"created_at", "direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'optional JSON string to specify the column and direction for ordering.'
            example: '{"colName":"created_at", "direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'optional JSON string containing search parameters.'
          example: '{"courseCategoryIds":[],"courseName":"course-1","status":"In Progress"}'
          required: false
          schema:
            type: string
            description: 'optional JSON string containing search parameters.'
            example: '{"courseCategoryIds":[],"courseName":"course-1","status":"In Progress"}'
        -
          in: query
          name: context
          description: 'The context for the activities.'
          example: '"admin"'
          required: true
          schema:
            type: string
            description: 'The context for the activities.'
            example: '"admin"'
        -
          in: query
          name: portalId
          description: 'The ID of the portal.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The ID of the portal.'
            example: 1
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 15
                      verb: ENROLLED
                      created_at: 'Aug 09, 2020 10:27 AM'
                      message: 'John Doe is enrolled to course 1'
                      course: 'course 1'
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 15
                        verb: ENROLLED
                        created_at: 'Aug 09, 2020 10:27 AM'
                        message: 'John Doe is enrolled to course 1'
                        course: 'course 1'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 15
                        verb:
                          type: string
                          example: ENROLLED
                        created_at:
                          type: string
                          example: 'Aug 09, 2020 10:27 AM'
                        message:
                          type: string
                          example: 'John Doe is enrolled to course 1'
                        course:
                          type: string
                          example: 'course 1'
      tags:
        - Users
      security: []
  /api/user-orders:
    get:
      summary: 'Retrieve User Orders'
      operationId: retrieveUserOrders
      description: "Returns all orders of a specified user in a paginated format.\nSupports filtering, sorting, and context-based queries."
      parameters:
        -
          in: query
          name: user_id
          description: 'ID of the user. Defaults to the authenticated user if not provided.'
          example: 4
          required: true
          schema:
            type: integer
            description: 'ID of the user. Defaults to the authenticated user if not provided.'
            example: 4
        -
          in: query
          name: page_size
          description: 'Number of records per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'Number of records per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'Current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'Current page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'optional JSON string to specify the column and direction for ordering.'
          example: '{"colName":"created_at", "direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'optional JSON string to specify the column and direction for ordering.'
            example: '{"colName":"created_at", "direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'optional JSON string containing search parameters.'
          example: '{"courseCategoryIds":[],"courseName":"course-1","status":"In Progress"}'
          required: false
          schema:
            type: string
            description: 'optional JSON string containing search parameters.'
            example: '{"courseCategoryIds":[],"courseName":"course-1","status":"In Progress"}'
        -
          in: query
          name: context
          description: 'The context for the activities.'
          example: '"admin"'
          required: true
          schema:
            type: string
            description: 'The context for the activities.'
            example: '"admin"'
        -
          in: query
          name: portalId
          description: 'The ID of the portal.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The ID of the portal.'
            example: 1
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 15
                      verb: ENROLLED
                      created_at: 'Aug 09, 2020 10:27 AM'
                      message: 'John Doe is enrolled to course 1'
                      course: 'course 1'
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 15
                        verb: ENROLLED
                        created_at: 'Aug 09, 2020 10:27 AM'
                        message: 'John Doe is enrolled to course 1'
                        course: 'course 1'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 15
                        verb:
                          type: string
                          example: ENROLLED
                        created_at:
                          type: string
                          example: 'Aug 09, 2020 10:27 AM'
                        message:
                          type: string
                          example: 'John Doe is enrolled to course 1'
                        course:
                          type: string
                          example: 'course 1'
      tags:
        - Users
      security: []
  '/api/user-certificates/{id}':
    get:
      summary: 'Get user certificates.'
      operationId: getUserCertificates
      description: 'Retrieves a paginated list of certificates for a specific user, with optional filtering, sorting, and portal-based context.'
      parameters:
        -
          in: query
          name: page_size
          description: 'Number of records per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'Number of records per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'Page number to retrieve.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'Page number to retrieve.'
            example: 1
        -
          in: query
          name: order_by
          description: 'json Sort options in JSON format.'
          example: '[{"field":"issued_at","direction":"desc"}]'
          required: false
          schema:
            type: string
            description: 'json Sort options in JSON format.'
            example: '[{"field":"issued_at","direction":"desc"}]'
        -
          in: query
          name: search_param
          description: 'json Search filters in JSON format.'
          example: '[{"field":"title","value":"AWS"}]'
          required: false
          schema:
            type: string
            description: 'json Search filters in JSON format.'
            example: '[{"field":"title","value":"AWS"}]'
        -
          in: query
          name: return_type
          description: 'Optional return type.'
          example: '"summary"'
          required: false
          schema:
            type: string
            description: 'Optional return type.'
            example: '"summary"'
        -
          in: query
          name: portalId
          description: 'Optional portal ID for context.'
          example: 3
          required: false
          schema:
            type: integer
            description: 'Optional portal ID for context.'
            example: 3
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    title: 'AWS Certified Solutions Architect'
                    issued_at: '2023-08-01'
                    valid_till: '2026-08-01'
                    issuer: Amazon
                    status: active
      tags:
        - Users
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the user or "undefined" to use the authenticated user.'
        example: '42'
        required: true
        schema:
          type: string
  '/api/user/{id}/delete-certificate':
    put:
      summary: 'Deletes a certificate issued to a user.'
      operationId: deletesACertificateIssuedToAUser
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Certificate Deleted Successfully'
                properties:
                  message:
                    type: string
                    example: 'Certificate Deleted Successfully'
      tags:
        - Users
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'ID of the user certificate.'
                  example: 1
              required:
                - id
      security: []
  /api/update-certificate-dates:
    put:
      summary: 'Update Certificate Issue and Expiry Dates'
      operationId: updateCertificateIssueAndExpiryDates
      description: "This API request is used to update the issue date and expiry date of a user's certificate."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Date Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Date Updated Successfully'
      tags:
        - Users
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                rowId:
                  type: integer
                  description: 'ID of the user certificate row.'
                  example: 1
                newIssueDate:
                  type: string
                  description: 'New issue date of the certificate in Y-m-d H:i:s format.'
                  example: '2020-08-15 10:00:00'
                newExpiryDate:
                  type: string
                  description: 'New expiry date of the certificate in Y-m-d H:i:s format.'
                  example: '2020-08-15 10:00:00'
              required:
                - rowId
                - newIssueDate
                - newExpiryDate
      security: []
  '/api/default-address/{id}':
    get:
      summary: 'Retrieves the default address of a user.'
      operationId: retrievesTheDefaultAddressOfAUser
      description: ''
      parameters:
        -
          in: query
          name: type
          description: 'optional Type of the address to be retrieved.'
          example: 'billing_address or shipping_address'
          required: false
          schema:
            type: string
            description: 'optional Type of the address to be retrieved.'
            example: 'billing_address or shipping_address'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  isDefault: false
                  fullName: 'John Doe'
                  addressLine1: 'Boring Street'
                  addressLine2: 'Awesome Colony'
                  zipcode: '123456'
                  city: Mumbai
                  state: MH
                  country: IN
                properties:
                  id:
                    type: integer
                    example: 1
                  isDefault:
                    type: boolean
                    example: false
                  fullName:
                    type: string
                    example: 'John Doe'
                  addressLine1:
                    type: string
                    example: 'Boring Street'
                  addressLine2:
                    type: string
                    example: 'Awesome Colony'
                  zipcode:
                    type: string
                    example: '123456'
                  city:
                    type: string
                    example: Mumbai
                  state:
                    type: string
                    example: MH
                  country:
                    type: string
                    example: IN
      tags:
        - Users
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the user.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/getaddress/{id}':
    get:
      summary: 'Retrieves the address of a user by address ID.'
      operationId: retrievesTheAddressOfAUserByAddressID
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  isDefault: false
                  fullName: 'John Doe'
                  addressLine1: 'Boring Street'
                  addressLine2: 'Awesome Colony'
                  zipcode: '123456'
                  city: Mumbai
                  state: MH
                  country: IN
                properties:
                  id:
                    type: integer
                    example: 1
                  isDefault:
                    type: boolean
                    example: false
                  fullName:
                    type: string
                    example: 'John Doe'
                  addressLine1:
                    type: string
                    example: 'Boring Street'
                  addressLine2:
                    type: string
                    example: 'Awesome Colony'
                  zipcode:
                    type: string
                    example: '123456'
                  city:
                    type: string
                    example: Mumbai
                  state:
                    type: string
                    example: MH
                  country:
                    type: string
                    example: IN
      tags:
        - Users
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the address.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/user/updateAddress/{id}':
    post:
      summary: "Update a user's address."
      operationId: updateAUsersAddress
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Address updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Address updated successfully'
      tags:
        - Users
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                fullName:
                  type: required
                  description: 'Full name of the user.'
                  example: 'John Doe'
                orgName:
                  type: optional
                  description: 'Organization Name.'
                  example: 'ABC Company'
                orgVatId:
                  type: optional
                  description: 'Organization VAT ID.'
                  example: '1234567890'
                addressLine1:
                  type: required
                  description: 'Address Line 1.'
                  example: 'Boring Street'
                addressLine2:
                  type: optional
                  description: 'Address Line 2.'
                  example: 'Awesome Colony'
                zipcode:
                  type: required
                  description: Zipcode.
                  example: '123456'
                city:
                  type: required
                  description: City.
                  example: Mumbai
                state:
                  type: optional
                  description: State.
                  example: MH
                country:
                  type: required
                  description: Country.
                  example: IN
                isDefault:
                  type: required
                  description: 'Whether the address is default or not.'
                  example: 'true'
                userId:
                  type: required
                  description: 'ID of the user.'
                  example: '1'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the address.'
        example: '1'
        required: true
        schema:
          type: string
  /api/user/reports/user-detailed:
    get:
      summary: 'Retrieves the detailed report for all courses of a user. Returned data contains information like total number of modules and number of courses in different status(In Progress, Not Started and Completed).'
      operationId: retrievesTheDetailedReportForAllCoursesOfAUserReturnedDataContainsInformationLikeTotalNumberOfModulesAndNumberOfCoursesInDifferentStatusInProgressNotStartedAndCompleted
      description: 'Example - [1,0]. You can use these data for graphs representation as well.'
      parameters:
        -
          in: query
          name: user_id
          description: 'ID of the user.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the user.'
            example: '1'
        -
          in: query
          name: page_size
          description: 'The number of the submissions you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the submissions you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"registered_on","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"registered_on","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'For searching items based on students name or emaila and status of the course.'
          example: '{"nameOrEmail":"","status":[]}'
          required: false
          schema:
            type: string
            description: 'For searching items based on students name or emaila and status of the course.'
            example: '{"nameOrEmail":"","status":[]}'
        -
          in: query
          name: portalId
          description: 'For listing courses assigned to a specific portal.'
          example: '{"portalId":1}'
          required: false
          schema:
            type: string
            description: 'For listing courses assigned to a specific portal.'
            example: '{"portalId":1}'
        -
          in: query
          name: searchPortalIds
          description: 'For listing courses assigned to multiple portals.'
          example: '{"searchPortalIds":[1,2]}'
          required: false
          schema:
            type: string
            description: 'For listing courses assigned to multiple portals.'
            example: '{"searchPortalIds":[1,2]}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  courseName: 'course 1'
                  featuredImage: null
                  recordsTotal: 3
                  totalNotStarted: 1
                  totalInProgress: 1
                  totalCompleted: 1
                  recordsFiltered: 3
                  records:
                    -
                      first_name: Aom
                      last_name: Staff
                      email: dev@academyofmine.com
                      status: 'In Progress'
                      percent_complete: 45
                      access_status: Allowed
                      registered_on: 10-Aug-2020
                      started_on: 10-Aug-2020
                      completed_on: ''
                      expire_on: Never
                      last_accessed_on: '1 hour ago'
                      percent_achieved: null
                      total_time_spent: '0h 20m'
                      certifcate_issued: 'No'
                    -
                      first_name: Client
                      last_name: Admin
                      email: client@app.com
                      status: 'Not Started'
                      percent_complete: 0
                      access_status: Allowed
                      registered_on: 09-Aug-2020
                      started_on: ''
                      completed_on: ''
                      expire_on: 12-Aug-2023
                      last_accessed_on: Never
                      percent_achieved: null
                      total_time_spent: '0h 0m'
                      certifcate_issued: 'Yes'
                    -
                      first_name: Demo
                      last_name: Student
                      email: student@app.com
                      status: Completed
                      percent_complete: 50
                      access_status: Allowed
                      registered_on: 03-Aug-2020
                      started_on: 03-Aug-2020
                      completed_on: 03-Aug-2020
                      expire_on: Never
                      last_accessed_on: '6 days ago'
                      percent_achieved: 0
                      total_time_spent: '0h 0m'
                      certifcate_issued: 'Yes'
                properties:
                  courseName:
                    type: string
                    example: 'course 1'
                  featuredImage:
                    type: string
                    example: null
                  recordsTotal:
                    type: integer
                    example: 3
                  totalNotStarted:
                    type: integer
                    example: 1
                  totalInProgress:
                    type: integer
                    example: 1
                  totalCompleted:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 3
                  records:
                    type: array
                    example:
                      -
                        first_name: Aom
                        last_name: Staff
                        email: dev@academyofmine.com
                        status: 'In Progress'
                        percent_complete: 45
                        access_status: Allowed
                        registered_on: 10-Aug-2020
                        started_on: 10-Aug-2020
                        completed_on: ''
                        expire_on: Never
                        last_accessed_on: '1 hour ago'
                        percent_achieved: null
                        total_time_spent: '0h 20m'
                        certifcate_issued: 'No'
                      -
                        first_name: Client
                        last_name: Admin
                        email: client@app.com
                        status: 'Not Started'
                        percent_complete: 0
                        access_status: Allowed
                        registered_on: 09-Aug-2020
                        started_on: ''
                        completed_on: ''
                        expire_on: 12-Aug-2023
                        last_accessed_on: Never
                        percent_achieved: null
                        total_time_spent: '0h 0m'
                        certifcate_issued: 'Yes'
                      -
                        first_name: Demo
                        last_name: Student
                        email: student@app.com
                        status: Completed
                        percent_complete: 50
                        access_status: Allowed
                        registered_on: 03-Aug-2020
                        started_on: 03-Aug-2020
                        completed_on: 03-Aug-2020
                        expire_on: Never
                        last_accessed_on: '6 days ago'
                        percent_achieved: 0
                        total_time_spent: '0h 0m'
                        certifcate_issued: 'Yes'
                    items:
                      type: object
                      properties:
                        first_name:
                          type: string
                          example: Aom
                        last_name:
                          type: string
                          example: Staff
                        email:
                          type: string
                          example: dev@academyofmine.com
                        status:
                          type: string
                          example: 'In Progress'
                        percent_complete:
                          type: integer
                          example: 45
                        access_status:
                          type: string
                          example: Allowed
                        registered_on:
                          type: string
                          example: 10-Aug-2020
                        started_on:
                          type: string
                          example: 10-Aug-2020
                        completed_on:
                          type: string
                          example: ''
                        expire_on:
                          type: string
                          example: Never
                        last_accessed_on:
                          type: string
                          example: '1 hour ago'
                        percent_achieved:
                          type: string
                          example: null
                        total_time_spent:
                          type: string
                          example: '0h 20m'
                        certifcate_issued:
                          type: string
                          example: 'No'
      tags:
        - Users
      security: []
  /api/users/report:
    get:
      summary: 'Retrieves a paginated report of users with custom user data.'
      operationId: retrievesAPaginatedReportOfUsersWithCustomUserData
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'Number of the result row you want in each page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'Number of the result row you want in each page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number.'
            example: '1'
        -
          in: query
          name: registered_between
          description: 'Date range filter for user registration.'
          example: '["2023-01-01", "2023-12-31"]'
          required: true
          schema:
            type: string
            description: 'Date range filter for user registration.'
            example: '["2023-01-01", "2023-12-31"]'
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n  \"records\": [\n    {\n      \"first_name\": \"John\",\n      \"last_name\": \"Doe\",\n      \"email\": \"john@example.com\",\n      \"user_type\": \"General\",\n      \"created_at\": \"2023-01-01 12:00:00\",\n      \"last_login\": \"2 days ago\",\n}\n  ],\n  \"headers\": [\n    \"custom_field_1\",\n    \"custom_field_2\"\n  ]\n}"
      tags:
        - Users
      security: []
  /api/user-subscriptions:
    get:
      summary: 'Retrieve User Subscriptions'
      operationId: retrieveUserSubscriptions
      description: "Returns all subscriptions of a specified user in a paginated format.\nSupports filtering and sorting."
      parameters:
        -
          in: query
          name: user_id
          description: 'optional ID of the user. Defaults to the authenticated user if not provided.'
          example: 4
          required: false
          schema:
            type: integer
            description: 'optional ID of the user. Defaults to the authenticated user if not provided.'
            example: 4
        -
          in: query
          name: page_size
          description: 'Number of records per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'Number of records per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'Current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'Current page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'optional JSON string to specify the column and direction for ordering.'
          example: '{"colName":"created_at", "direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'optional JSON string to specify the column and direction for ordering.'
            example: '{"colName":"created_at", "direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'optional JSON string containing search parameters.'
          example: '{"status":"Active"}'
          required: false
          schema:
            type: string
            description: 'optional JSON string containing search parameters.'
            example: '{"status":"Active"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 5
                  recordsFiltered: 5
                  records:
                    -
                      id: 1
                      subscription_name: 'Premium Plan'
                      status: Active
                      start_date: '2023-01-01'
                      end_date: '2023-12-31'
                properties:
                  recordsTotal:
                    type: integer
                    example: 5
                  recordsFiltered:
                    type: integer
                    example: 5
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        subscription_name: 'Premium Plan'
                        status: Active
                        start_date: '2023-01-01'
                        end_date: '2023-12-31'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        subscription_name:
                          type: string
                          example: 'Premium Plan'
                        status:
                          type: string
                          example: Active
                        start_date:
                          type: string
                          example: '2023-01-01'
                        end_date:
                          type: string
                          example: '2023-12-31'
      tags:
        - Users
      security: []
  /api/user-source:
    get:
      summary: 'Get all User Sources'
      operationId: getAllUserSources
      description: "Retrieves all the sources for a portal with pagination mode.\nYou can apply filter using search_param via name or identifier."
      parameters:
        -
          in: query
          name: portalId
          description: 'The id of the portal.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The id of the portal.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  records:
                    -
                      id: 1
                      name: Default
                      identifier: default
                      description: 'Default source of users.'
                      logoUrl: 'https://example.com/default.png'
                properties:
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: Default
                        identifier: default
                        description: 'Default source of users.'
                        logoUrl: 'https://example.com/default.png'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: Default
                        identifier:
                          type: string
                          example: default
                        description:
                          type: string
                          example: 'Default source of users.'
                        logoUrl:
                          type: string
                          example: 'https://example.com/default.png'
      tags:
        - Users
      security: []
  /api/user/portal-create:
    post:
      summary: 'Creates a new portal for a given user.'
      operationId: createsANewPortalForAGivenUser
      description: ''
      parameters:
        -
          in: query
          name: portalId
          description: 'The portal ID to filter by portal and sub-portals. Use -1 to skip portal filtering.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'The portal ID to filter by portal and sub-portals. Use -1 to skip portal filtering.'
            example: 5
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portals created successfully'
                properties:
                  message:
                    type: string
                    example: 'Portals created successfully'
      tags:
        - Users
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                userId:
                  type: integer
                  description: 'The ID of the user to create the portal for.'
                  example: 12
                portals:
                  type: array
                  description: 'The array of portals to create. Each portal should contain "name", "referralCode", "totalSeat", "userType", "portalType", "status", "subscriptionId", "expiryDate", "expiryMessage", and "parentPortalId".'
                  example:
                    -
                      name: 'My New Portal'
                      referralCode: REF123
                      totalSeat: 50
                      userType: admin
                      portalType: education
                      status: active
                      subscriptionId: 101
                      expiryDate: '2025-12-31'
                      expiryMessage: 'Subscription ends soon'
                      parentPortalId: 1
                  items:
                    type: string
                clonePortalAdmins:
                  type: boolean
                  description: 'Whether to clone the portal admins or not.'
                  example: true
                cloneBrandingNotifications:
                  type: boolean
                  description: 'Whether to clone the branding notifications or not.'
                  example: false
              required:
                - userId
                - portals
                - clonePortalAdmins
                - cloneBrandingNotifications
      security: []
  /api/users/enrolled-learningpaths:
    get:
      summary: 'Retrieves all learning paths for a given user.'
      operationId: retrievesAllLearningPathsForAGivenUser
      description: ''
      parameters:
        -
          in: query
          name: user_id
          description: 'User ID to filter learning paths.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'User ID to filter learning paths.'
            example: '1'
        -
          in: query
          name: portalId
          description: 'Portal ID to filter learning paths. If -1, it will return all learning paths.'
          example: '-1'
          required: true
          schema:
            type: string
            description: 'Portal ID to filter learning paths. If -1, it will return all learning paths.'
            example: '-1'
        -
          in: query
          name: viewType
          description: 'View type of the user.'
          example: self
          required: true
          schema:
            type: string
            description: 'View type of the user.'
            example: self
        -
          in: query
          name: page_size
          description: 'Number of records to return per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'Number of records to return per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'Order by parameters.'
          example: '{"colName":"started_on","direction":"desc"}'
          required: true
          schema:
            type: string
            description: 'Order by parameters.'
            example: '{"colName":"started_on","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'Search parameters related to learning path.'
          example: '{"status":["Not Started","In Progress"],"nameOrEmail":"John Doe"}'
          required: true
          schema:
            type: string
            description: 'Search parameters related to learning path.'
            example: '{"status":["Not Started","In Progress"],"nameOrEmail":"John Doe"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 12
                  recordsFiltered: 12
                  records:
                    -
                      id: 1
                      featuredImageUrl: 'http://example.com/featured-image.jpg'
                      launchSlug: 'http://example.com/launch-learning-path'
                      learningPathName: 'Learning Path 1'
                      status: 'Not Started'
                      display_status: 'Not Started'
                      percentComplete: 0
                      registered_on: 22-02-2022
                      started_on: ''
                      completed_on: ''
                      certificateCount: 0
                      totalLPCourses: 5
                      completedLpCourses: 0
                      rating: 4.5
                      totalEstimatedTime: '2 hours'
                  name: 'John Doe'
                  email: john@example.com
                  userType: Learner
                  avatar: 'http://example.com/avatar.jpg'
                properties:
                  recordsTotal:
                    type: integer
                    example: 12
                  recordsFiltered:
                    type: integer
                    example: 12
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        featuredImageUrl: 'http://example.com/featured-image.jpg'
                        launchSlug: 'http://example.com/launch-learning-path'
                        learningPathName: 'Learning Path 1'
                        status: 'Not Started'
                        display_status: 'Not Started'
                        percentComplete: 0
                        registered_on: 22-02-2022
                        started_on: ''
                        completed_on: ''
                        certificateCount: 0
                        totalLPCourses: 5
                        completedLpCourses: 0
                        rating: 4.5
                        totalEstimatedTime: '2 hours'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        featuredImageUrl:
                          type: string
                          example: 'http://example.com/featured-image.jpg'
                        launchSlug:
                          type: string
                          example: 'http://example.com/launch-learning-path'
                        learningPathName:
                          type: string
                          example: 'Learning Path 1'
                        status:
                          type: string
                          example: 'Not Started'
                        display_status:
                          type: string
                          example: 'Not Started'
                        percentComplete:
                          type: integer
                          example: 0
                        registered_on:
                          type: string
                          example: 22-02-2022
                        started_on:
                          type: string
                          example: ''
                        completed_on:
                          type: string
                          example: ''
                        certificateCount:
                          type: integer
                          example: 0
                        totalLPCourses:
                          type: integer
                          example: 5
                        completedLpCourses:
                          type: integer
                          example: 0
                        rating:
                          type: number
                          example: 4.5
                        totalEstimatedTime:
                          type: string
                          example: '2 hours'
                  name:
                    type: string
                    example: 'John Doe'
                  email:
                    type: string
                    example: john@example.com
                  userType:
                    type: string
                    example: Learner
                  avatar:
                    type: string
                    example: 'http://example.com/avatar.jpg'
      tags:
        - Users
      security: []
  /api/users/portalLearningPaths:
    get:
      summary: 'Retrieves learning paths associated with the portal, filtered by the search parameters.'
      operationId: retrievesLearningPathsAssociatedWithThePortalFilteredByTheSearchParameters
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of results per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of results per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'optional The column to sort the results by.'
          example: '{"colName": "name", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'optional The column to sort the results by.'
            example: '{"colName": "name", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'optional The search query parameters.'
          example: '{"name": "Learning Path 1", "status": ["registered", "started"]}'
          required: false
          schema:
            type: string
            description: 'optional The search query parameters.'
            example: '{"name": "Learning Path 1", "status": ["registered", "started"]}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  learningPaths:
                    -
                      id: 1
                      learningPathId: 1
                      type: public
                      learningPathName: 'Learning Path 1'
                      featureImage: 'http://example.com/learning-path-image.jpg'
                      display_status: Registered
                      percentComplete: 0
                      isEnrolled: true
                      certificateCount: 0
                      launchSlug: 'http://example.com/portal/learning-path/1/launch'
                      totalLPCourses: 5
                      completedLpCourses: 2
                      rating: 4.5
                      totalEstimatedTime: '2 hours'
                    -
                      id: 2
                      learningPathId: 2
                      type: private
                      learningPathName: 'Learning Path 2'
                      featureImage: 'http://example.com/learning-path-image.jpg'
                      display_status: 'Not Enrolled'
                      percentComplete: 0
                      isEnrolled: false
                      certificateCount: 0
                      launchSlug: 'http://example.com/portal/learning-path/2/launch'
                      totalLPCourses: 5
                      completedLpCourses: 0
                      rating: null
                      totalEstimatedTime: '2 hours'
                  totalRecords: 10
                  recordsFiltered: 10
                properties:
                  learningPaths:
                    type: array
                    example:
                      -
                        id: 1
                        learningPathId: 1
                        type: public
                        learningPathName: 'Learning Path 1'
                        featureImage: 'http://example.com/learning-path-image.jpg'
                        display_status: Registered
                        percentComplete: 0
                        isEnrolled: true
                        certificateCount: 0
                        launchSlug: 'http://example.com/portal/learning-path/1/launch'
                        totalLPCourses: 5
                        completedLpCourses: 2
                        rating: 4.5
                        totalEstimatedTime: '2 hours'
                      -
                        id: 2
                        learningPathId: 2
                        type: private
                        learningPathName: 'Learning Path 2'
                        featureImage: 'http://example.com/learning-path-image.jpg'
                        display_status: 'Not Enrolled'
                        percentComplete: 0
                        isEnrolled: false
                        certificateCount: 0
                        launchSlug: 'http://example.com/portal/learning-path/2/launch'
                        totalLPCourses: 5
                        completedLpCourses: 0
                        rating: null
                        totalEstimatedTime: '2 hours'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        learningPathId:
                          type: integer
                          example: 1
                        type:
                          type: string
                          example: public
                        learningPathName:
                          type: string
                          example: 'Learning Path 1'
                        featureImage:
                          type: string
                          example: 'http://example.com/learning-path-image.jpg'
                        display_status:
                          type: string
                          example: Registered
                        percentComplete:
                          type: integer
                          example: 0
                        isEnrolled:
                          type: boolean
                          example: true
                        certificateCount:
                          type: integer
                          example: 0
                        launchSlug:
                          type: string
                          example: 'http://example.com/portal/learning-path/1/launch'
                        totalLPCourses:
                          type: integer
                          example: 5
                        completedLpCourses:
                          type: integer
                          example: 2
                        rating:
                          type: number
                          example: 4.5
                        totalEstimatedTime:
                          type: string
                          example: '2 hours'
                  totalRecords:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
      tags:
        - Users
      security: []
    parameters:
      -
        in: path
        name: portalId
        description: 'Portal ID of the user.'
        example: '1'
        required: true
        schema:
          type: string
  /api/membership/user-contents:
    get:
      summary: 'Retrieve Membership Content'
      operationId: retrieveMembershipContent
      description: "Fetches and returns a paginated list of content available to a user through their membership.\nThe content includes courses and modules, which can be filtered and sorted based on the input parameters."
      parameters:
        -
          in: query
          name: page_size
          description: 'Number of records per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'Number of records per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'Current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'Current page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'optional JSON string specifying the column and direction for ordering.'
          example: '{"colName":"created_at", "direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'optional JSON string specifying the column and direction for ordering.'
            example: '{"colName":"created_at", "direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'optional JSON string containing search parameters.'
          example: '{"type":"video", "nameOrDescription":"Introduction"}'
          required: false
          schema:
            type: string
            description: 'optional JSON string containing search parameters.'
            example: '{"type":"video", "nameOrDescription":"Introduction"}'
        -
          in: query
          name: portalId
          description: 'ID of the portal for filtering membership content. Use -1 for default behavior.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'ID of the portal for filtering membership content. Use -1 for default behavior.'
            example: 1
        -
          in: query
          name: viewType
          description: 'Specifies the view type. "self" for personal view, others for different portal settings.'
          example: '"self"'
          required: true
          schema:
            type: string
            description: 'Specifies the view type. "self" for personal view, others for different portal settings.'
            example: '"self"'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  activeMembership: true
                  recordsTotal: 100
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      name: 'Course 1'
                      slug: course-1
                      type: Course
                      description: 'Course description'
                      enrollButton: null
                      duration: '2 hours'
                      launchUrl: 'http://example.com/launch'
                      user_id:
                        - 4
                      created_at: '2023-01-01'
                properties:
                  activeMembership:
                    type: boolean
                    example: true
                  recordsTotal:
                    type: integer
                    example: 100
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Course 1'
                        slug: course-1
                        type: Course
                        description: 'Course description'
                        enrollButton: null
                        duration: '2 hours'
                        launchUrl: 'http://example.com/launch'
                        user_id:
                          - 4
                        created_at: '2023-01-01'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Course 1'
                        slug:
                          type: string
                          example: course-1
                        type:
                          type: string
                          example: Course
                        description:
                          type: string
                          example: 'Course description'
                        enrollButton:
                          type: string
                          example: null
                        duration:
                          type: string
                          example: '2 hours'
                        launchUrl:
                          type: string
                          example: 'http://example.com/launch'
                        user_id:
                          type: array
                          example:
                            - 4
                          items:
                            type: integer
                        created_at:
                          type: string
                          example: '2023-01-01'
      tags:
        - Users
      security: []
  /api/users/fieldtype/lookup:
    get:
      summary: 'Custom User Field Type Lookup'
      operationId: customUserFieldTypeLookup
      description: "Provides a list of available custom user field types.\nEach type is represented by a database value and a display value."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: text
                    display_value: 'Text Field'
                  -
                    db_value: textarea
                    display_value: 'Text Area'
                  -
                    db_value: date
                    display_value: Date
                  -
                    db_value: radio
                    display_value: 'Single Select'
                  -
                    db_value: checkbox
                    display_value: 'Multiple Select'
                  -
                    db_value: dropdown
                    display_value: 'Drop Down'
      tags:
        - Users
      security: []
  /api/users/customUserFields:
    get:
      summary: 'Retrieve Custom User Fields that needs to be shown on the Registration page'
      operationId: retrieveCustomUserFieldsThatNeedsToBeShownOnTheRegistrationPage
      description: 'Retrieves the details of pre saved Custom User Fields.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  fields:
                    -
                      id: 1
                      type: text
                      label: 'How you left'
                      defaultValue: null
                      isRequired: false
                      optionLabel: []
                      isFieldOnRegistrationPage: false
                      isFieldOnCertificate: true
                      includeInReportExports:
                        - export-users
                        - export-orders
                    -
                      id: 2
                      type: textarea
                      label: 'What is your home address'
                      defaultValue: null
                      isRequired: true
                      optionLabel: []
                      isFieldOnRegistrationPage: true
                      isFieldOnCertificate: false
                      includeInReportExports: []
                properties:
                  fields:
                    type: array
                    example:
                      -
                        id: 1
                        type: text
                        label: 'How you left'
                        defaultValue: null
                        isRequired: false
                        optionLabel: []
                        isFieldOnRegistrationPage: false
                        isFieldOnCertificate: true
                        includeInReportExports:
                          - export-users
                          - export-orders
                      -
                        id: 2
                        type: textarea
                        label: 'What is your home address'
                        defaultValue: null
                        isRequired: true
                        optionLabel: []
                        isFieldOnRegistrationPage: true
                        isFieldOnCertificate: false
                        includeInReportExports: []
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        type:
                          type: string
                          example: text
                        label:
                          type: string
                          example: 'How you left'
                        defaultValue:
                          type: string
                          example: null
                        isRequired:
                          type: boolean
                          example: false
                        optionLabel:
                          type: array
                          example: []
                        isFieldOnRegistrationPage:
                          type: boolean
                          example: false
                        isFieldOnCertificate:
                          type: boolean
                          example: true
                        includeInReportExports:
                          type: array
                          example:
                            - export-users
                            - export-orders
                          items:
                            type: string
      tags:
        - Users
      security: []
    put:
      summary: 'Update custom user fields.'
      operationId: updateCustomUserFields
      description: "Updates the details of the fields in \"Custom User Fields\" table.\nIf the field is not present in the table, it will be added.\nIf the field is not present in the request, it will be deleted from the table."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Fields updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Fields updated successfully'
      tags:
        - Users
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                fields:
                  type: array
                  description: 'List of fields to be saved.'
                  example:
                    - possimus
                  items:
                    type: string
              required:
                - fields
      security: []
  /api/users/customUserFieldsReports/lookup:
    get:
      summary: 'Lookup for custom user fields report exports'
      operationId: lookupForCustomUserFieldsReportExports
      description: 'Retrieves a list of reports that custom user fields can be included in.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "[\n    {\"db_value\": \"export-users\", \"display_value\": \"Export Users\"},\n    {\"db_value\": \"course-insight\", \"display_value\": \"Course Insight\"},\n    {\"db_value\": \"export-orders\", \"display_value\": \"Export Orders\"},\n]"
      tags:
        - Users
      security: []
  /api/users/can-delete-field:
    get:
      summary: 'Checks if a custom user field can be deleted.'
      operationId: checksIfACustomUserFieldCanBeDeleted
      description: ''
      parameters:
        -
          in: query
          name: fieldToDelete
          description: 'Field data in JSON format.'
          example: '{"userMetaKey":"dob","label":"Date Of Birth","type":"date","isRequired":false,"optionsLabel":[]}. example: {"userMetaKey":"custom_field_1","label":"Custom Field 1","type":"text","isRequired":false,"optionsLabel":[]}'
          required: true
          schema:
            type: string
            description: 'Field data in JSON format.'
            example: '{"userMetaKey":"dob","label":"Date Of Birth","type":"date","isRequired":false,"optionsLabel":[]}. example: {"userMetaKey":"custom_field_1","label":"Custom Field 1","type":"text","isRequired":false,"optionsLabel":[]}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  canDeleteField: true
                  message: 'This field can not be deleted as some user data is associated with it. Please contact administrator.'
                  certificateTemplates: []
                properties:
                  canDeleteField:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'This field can not be deleted as some user data is associated with it. Please contact administrator.'
                  certificateTemplates:
                    type: array
                    example: []
      tags:
        - Users
      security: []
  '/api/user/badges/{id}':
    get:
      summary: 'Retrieve the badges and the count of each badge a user has earned'
      operationId: retrieveTheBadgesAndTheCountOfEachBadgeAUserHasEarned
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    title: Gold
                    badgeIconUrl: /images/badges/Badge_1.png
                    points: 1
                    organizationId: 1
                    count: 3
                  -
                    id: 2
                    title: Silver
                    badgeIconUrl: /images/badges/Badge_2.png
                    points: 2
                    organizationId: 1
                    count: 1
      tags:
        - Users
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the user.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/user/leaderboard/{id}':
    get:
      summary: 'Get the leaderboard information for a user'
      operationId: getTheLeaderboardInformationForAUser
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "[\n    \"rankedUsers\": [\n        {\n            \"id\": 1,\n            \"rank\": 1,\n            \"firstName\": \"John\",\n            \"lastName\": \"Doe\",\n            \"points\": 100,\n            \"badgeCount\": 10\n        },\n        {\n            \"id\": 2,\n            \"rank\": 2,\n            \"firstName\": \"Jane\",\n            \"lastName\": \"Doe\",\n            \"points\": 80,\n            \"badgeCount\": 5\n        }\n    ],\n    \"userTier\": \"Gold\",\n    \"userRank\": 1\n]"
      tags:
        - Users
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the user.'
        example: '1'
        required: true
        schema:
          type: string
  /api/user-meta/2fa:
    get:
      summary: 'Returns 2FA details for a user.'
      operationId: returns2FADetailsForAUser
      description: ''
      parameters:
        -
          in: query
          name: user_id
          description: 'optional ID of the user.'
          example: 4
          required: false
          schema:
            type: integer
            description: 'optional ID of the user.'
            example: 4
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is2FactorAuthActive: true
                  qr_code: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAZdEVYdFNvZnR3YXJlAE1pY3Jvc29mdCBPZmZpY2UgTWF0aXZpY2FsIEJ1aWx0aW5nIChNaW5pbnNpemUpd2l0aCBHZW5lcmF0b3Igd2l0aCBQb3NpdGljIFRleHQgLSBDb3B5cmlnaHQgTmFtZSBmcm9tIHVuaXF1ZSBpZGVudGl0eQAAABh0RVh0VGh1bWI6OkRTVEVYUWhUQyBjb250ZW50LW1vc3QgdGh1bWIh4NApweCt4M6rAAAAAElFTkSuQmCC'
                  string_code: 'string code'
                properties:
                  is2FactorAuthActive:
                    type: boolean
                    example: true
                  qr_code:
                    type: string
                    example: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAZdEVYdFNvZnR3YXJlAE1pY3Jvc29mdCBPZmZpY2UgTWF0aXZpY2FsIEJ1aWx0aW5nIChNaW5pbnNpemUpd2l0aCBHZW5lcmF0b3Igd2l0aCBQb3NpdGljIFRleHQgLSBDb3B5cmlnaHQgTmFtZSBmcm9tIHVuaXF1ZSBpZGVudGl0eQAAABh0RVh0VGh1bWI6OkRTVEVYUWhUQyBjb250ZW50LW1vc3QgdGh1bWIh4NApweCt4M6rAAAAAElFTkSuQmCC'
                  string_code:
                    type: string
                    example: 'string code'
      tags:
        - Users
      security: []
  /api/user/prepareTwoFactorAuth:
    post:
      summary: 'Prepares QR code for Two factor authentication.'
      operationId: preparesQRCodeForTwoFactorAuthentication
      description: 'Returns QR code, URI code and String code for users to authenticate themselves using their authenticator app.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  as_qr_code: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAZdEVYdFNvZnR3YXJlAE1pY3Jvc29mdCBPZmZpY2UgTWF0aXZpY2FsIEJ1aWx0aW5nIChNaW5pbnNpemUpd2l0aCBHZW5lcmF0b3Igd2l0aCBQb3NpdGljIFRleHQgLSBDb3B5cmlnaHQgTmFtZSBmcm9tIHVuaXF1ZSBpZGVudGl0eQAAABh0RVh0VGh1bWI6OkRTVEVYUWhUQyBjb250ZW50LW1vc3QgdGh1bWIh4NApweCt4M6rAAAAAElFTkSuQmCC'
                  as_uri: 'otpauth://totp/AOM?secret=base32secret&issuer=AOM'
                  as_string: base32secret
                properties:
                  as_qr_code:
                    type: string
                    example: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAZdEVYdFNvZnR3YXJlAE1pY3Jvc29mdCBPZmZpY2UgTWF0aXZpY2FsIEJ1aWx0aW5nIChNaW5pbnNpemUpd2l0aCBHZW5lcmF0b3Igd2l0aCBQb3NpdGljIFRleHQgLSBDb3B5cmlnaHQgTmFtZSBmcm9tIHVuaXF1ZSBpZGVudGl0eQAAABh0RVh0VGh1bWI6OkRTVEVYUWhUQyBjb250ZW50LW1vc3QgdGh1bWIh4NApweCt4M6rAAAAAElFTkSuQmCC'
                  as_uri:
                    type: string
                    example: 'otpauth://totp/AOM?secret=base32secret&issuer=AOM'
                  as_string:
                    type: string
                    example: base32secret
      tags:
        - Users
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                user_id:
                  type: integer
                  description: 'optional ID of the user.'
                  example: 4
      security: []
  /api/user/confirmTwoFactorAuth:
    post:
      summary: 'Confirms relation between AOM site and authenticator app for 2fa.'
      operationId: confirmsRelationBetweenAOMSiteAndAuthenticatorAppFor2fa
      description: 'User need to provided secret code from authenticator app. It enables Two factor authentication feature in the system for users.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: success
                  message: 'Two Factor Authentication activated'
                properties:
                  status:
                    type: string
                    example: success
                  message:
                    type: string
                    example: 'Two Factor Authentication activated'
      tags:
        - Users
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                user_id:
                  type: integer
                  description: 'optional ID of the user.'
                  example: 4
                secretCode:
                  type: string
                  description: 'Secret code from users authenticator app.'
                  example: '123456'
                qrCode:
                  type: string
                  description: 'QR code generated by prepareTwoFactor method.'
                  example: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAZdEVYdFNvZnR3YXJlAE1pY3Jvc29mdCBPZmZpY2UgTWF0aXZpY2FsIEJ1aWx0aW5nIChNaW5pbnNpemUpd2l0aCBHZW5lcmF0b3Igd2l0aCBQb3NpdGljIFRleHQgLSBDb3B5cmlnaHQgTmFtZSBmcm9tIHVuaXF1ZSBpZGVudGl0eQAAABh0RVh0VGh1bWI6OkRTVEVYUWhUQyBjb250ZW50LW1vc3QgdGh1bWIh4NApweCt4M6rAAAAAElFTkSuQmCC'
                stringCode:
                  type: string
                  description: 'String code generated by prepareTwoFactor method.'
                  example: base32secret
              required:
                - secretCode
                - qrCode
                - stringCode
      security: []
  /api/user/disableTwoFactorAuth:
    post:
      summary: 'Disable Two Factor Authentication for a user.'
      operationId: disableTwoFactorAuthenticationForAUser
      description: 'Disables Two factor authentication feature in the system for users.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '2factor authentication disabled successfully'
                  qrcode: null
                  stringcode: null
                properties:
                  message:
                    type: string
                    example: '2factor authentication disabled successfully'
                  qrcode:
                    type: string
                    example: null
                  stringcode:
                    type: string
                    example: null
      tags:
        - Users
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                user_id:
                  type: integer
                  description: 'optional ID of the user.'
                  example: 4
      security: []
  /api/sendCartReminderEmail:
    post:
      summary: 'Sends a reminder email to a user about their abandoned cart.'
      operationId: sendsAReminderEmailToAUserAboutTheirAbandonedCart
      description: ''
      parameters:
        -
          in: query
          name: id
          description: 'int The ID of the cart abandonment detail to send the reminder for.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'int The ID of the cart abandonment detail to send the reminder for.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Email send successfully'
                properties:
                  message:
                    type: string
                    example: 'Email send successfully'
      tags:
        - Users
      security: []
  /api/email/resendNewAccountEmail:
    post:
      summary: 'Resend New Account Email'
      operationId: resendNewAccountEmail
      description: 'Resends a new account email to the user. If the user is not found, it will be ignored.'
      parameters:
        -
          in: query
          name: portalId
          description: 'The Portal ID to which the user belongs.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The Portal ID to which the user belongs.'
            example: 1
        -
          in: query
          name: user_id
          description: 'string|array required The ID of the user who needs to receive a new account email.'
          example: 1
          required: false
          schema:
            type: integer
            description: 'string|array required The ID of the user who needs to receive a new account email.'
            example: 1
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: success
                  message: 'New Password is created and New Account Email Sent.'
                properties:
                  status:
                    type: string
                    example: success
                  message:
                    type: string
                    example: 'New Password is created and New Account Email Sent.'
      tags:
        - Users
      security: []
  /api/user-consents/tabularlist:
    get:
      summary: 'Loads user consents based on pagination parameters.'
      operationId: loadsUserConsentsBasedOnPaginationParameters
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of records to return per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'The number of records to return per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'The page number to return.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The page number to return.'
            example: 1
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  userConsents:
                    -
                      id: 101
                      consentDate: '2025-04-01T14:32:00Z'
                      consentId: CONSENT-XYZ123
                      country: US
                      ipAddress: 192.168.1.15
                      status: accepted
                      userId: 2001
                      userName: johndoe
                      createdAt: '2025-04-01T14:32:00Z'
                    -
                      id: 102
                      consentDate: '2025-04-02T09:15:43Z'
                      consentId: CONSENT-ABC456
                      country: DE
                      ipAddress: 203.0.113.45
                      status: rejected
                      userId: 2002
                      userName: janedoe
                      createdAt: '2025-04-02T09:15:43Z'
                  total: 50
                  recordsFiltered: 10
                properties:
                  userConsents:
                    type: array
                    example:
                      -
                        id: 101
                        consentDate: '2025-04-01T14:32:00Z'
                        consentId: CONSENT-XYZ123
                        country: US
                        ipAddress: 192.168.1.15
                        status: accepted
                        userId: 2001
                        userName: johndoe
                        createdAt: '2025-04-01T14:32:00Z'
                      -
                        id: 102
                        consentDate: '2025-04-02T09:15:43Z'
                        consentId: CONSENT-ABC456
                        country: DE
                        ipAddress: 203.0.113.45
                        status: rejected
                        userId: 2002
                        userName: janedoe
                        createdAt: '2025-04-02T09:15:43Z'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 101
                        consentDate:
                          type: string
                          example: '2025-04-01T14:32:00Z'
                        consentId:
                          type: string
                          example: CONSENT-XYZ123
                        country:
                          type: string
                          example: US
                        ipAddress:
                          type: string
                          example: 192.168.1.15
                        status:
                          type: string
                          example: accepted
                        userId:
                          type: integer
                          example: 2001
                        userName:
                          type: string
                          example: johndoe
                        createdAt:
                          type: string
                          example: '2025-04-01T14:32:00Z'
                  total:
                    type: integer
                    example: 50
                  recordsFiltered:
                    type: integer
                    example: 10
      tags:
        - Users
      security: []
  '/api/accredible/validate-key/{key}':
    get:
      summary: 'Validate Accredible API Key'
      operationId: validateAccredibleAPIKey
      description: 'Validates the API Key provided with the request'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: Success
                  status: success
                properties:
                  message:
                    type: string
                    example: Success
                  status:
                    type: string
                    example: success
      tags:
        - Accredible
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                key:
                  type: string
                  description: 'The API key that needs to be validated'
                  example: sunt
              required:
                - key
      security: []
  /api/accredible/group/lookup:
    get:
      summary: 'Accredible Groups Lookup'
      operationId: accredibleGroupsLookup
      description: 'Retrieves all the accredible groups. Helps while showing group names in dropdown elements.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  isEnabled: true
                  data:
                    -
                      id: 353767
                      name: group_aom_course
                    -
                      id: 353282
                      name: intro-ce
                    -
                      id: 352594
                      name: aom
                properties:
                  isEnabled:
                    type: boolean
                    example: true
                  data:
                    type: array
                    example:
                      -
                        id: 353767
                        name: group_aom_course
                      -
                        id: 353282
                        name: intro-ce
                      -
                        id: 352594
                        name: aom
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 353767
                        name:
                          type: string
                          example: group_aom_course
      tags:
        - Accredible
      security: []
  /api/announcement:
    post:
      summary: 'Create an Announcement'
      operationId: createAnAnnouncement
      description: "Updates an existing announcement with new content, expiry, and sending rules. Also updates the recipient list\ndepending on the sending rules."
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 45
                  message: 'Announcement Updated Successfully'
                properties:
                  id:
                    type: integer
                    example: 45
                  message:
                    type: string
                    example: 'Announcement Updated Successfully'
      tags:
        - Announcements
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The ID of the announcement (used for permission check).'
                  example: 45
                expiry:
                  type: string
                  description: 'nullable The expiration date of the announcement.'
                  example: '2025-12-31 23:59:59'
                heading:
                  type: string
                  description: 'The title or heading of the announcement.'
                  example: 'System Maintenance'
                content:
                  type: string
                  description: 'The message content of the announcement.'
                  example: 'The system will be down for maintenance tonight.'
                sending_rules:
                  type: string
                  description: 'Must be one of: all, specific_users, specific_course_users, specific_class_users, specific_portals.'
                  example: specific_users
                course_ids:
                  type: array
                  description: 'required_if:sending_rules,specific_course_users The list of course IDs if targeting specific course users.'
                  example:
                    - 101
                    - 102
                  items:
                    type: string
                portal_ids:
                  type: array
                  description: 'required_if:sending_rules,specific_portals The list of portal IDs if targeting specific portals.'
                  example:
                    - 201
                    - 202
                  items:
                    type: string
                user_ids:
                  type: array
                  description: 'required_if:sending_rules,specific_users The list of user IDs if targeting specific users.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                portalId:
                  type: integer
                  description: 'optional The portal ID for ownership context (nullable if -1).'
                  example: 5
              required:
                - id
                - heading
                - content
                - sending_rules
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the announcement to update.'
        example: 45
        required: true
        schema:
          type: integer
  /api/announcement/tabularlist:
    get:
      summary: 'Announcement Tabular List'
      operationId: announcementTabularList
      description: "Returns all the announcements in a tabular list format in paginated mode.\nYou can apply filter using search_param via heading(announcement heading)."
      parameters:
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: 5
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'For searching items based on field names.'
          example: '{"heading":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on field names.'
            example: '{"heading":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      heading: 'Test Announcement'
                      author: 'John Doe'
                      created_at: '2020-08-26 09:08'
                      content: 'This is a test announcement'
                      rules: all
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        heading: 'Test Announcement'
                        author: 'John Doe'
                        created_at: '2020-08-26 09:08'
                        content: 'This is a test announcement'
                        rules: all
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        heading:
                          type: string
                          example: 'Test Announcement'
                        author:
                          type: string
                          example: 'John Doe'
                        created_at:
                          type: string
                          example: '2020-08-26 09:08'
                        content:
                          type: string
                          example: 'This is a test announcement'
                        rules:
                          type: string
                          example: all
      tags:
        - Announcements
      security: []
  '/api/announcement/{id}':
    put:
      summary: 'Update an announcement.'
      operationId: updateAnAnnouncement
      description: ''
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 45
                  message: 'Announcement Updated Successfully'
                properties:
                  id:
                    type: integer
                    example: 45
                  message:
                    type: string
                    example: 'Announcement Updated Successfully'
      tags:
        - Announcements
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'ID of the announcement to be updated.'
                  example: 12
                expiry:
                  type: string
                  description: 'optional Date of expiration of announcement in Y-m-d format.'
                  example: '2020-08-05'
                heading:
                  type: string
                  description: 'The title of the announcement.'
                  example: 'New Announcement'
                content:
                  type: string
                  description: 'The message content of the announcement.'
                  example: 'The system will be down for maintenance tonight.'
                sending_rules:
                  type: string
                  description: 'Must be one of: all, specific_users, specific_course_users, specific_class_users, specific_portals.'
                  example: specific_users
                course_ids:
                  type: array
                  description: 'required_if:sending_rules,specific_course_users The list of course IDs if targeting specific course users.'
                  example:
                    - 101
                    - 102
                  items:
                    type: string
                portal_ids:
                  type: array
                  description: 'required_if:sending_rules,specific_portals The list of portal IDs if targeting specific portals.'
                  example:
                    - 201
                    - 202
                  items:
                    type: string
                user_ids:
                  type: array
                  description: 'required_if:sending_rules,specific_users The list of user IDs if targeting specific users.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                portalId:
                  type: integer
                  description: 'optional The portal ID for ownership context (nullable if -1).'
                  example: 5
              required:
                - id
                - heading
                - content
                - sending_rules
      security: []
    get:
      summary: 'Retrieve Announcement'
      operationId: retrieveAnnouncement
      description: 'Retrieves the details of the specified announcement. Helps in fetching announcement using its ID. (See Parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  heading: 'New Announcement'
                  content: 'This is for test purpose'
                  sending_rules: all
                  expiry: '2020-08-05'
                properties:
                  id:
                    type: integer
                    example: 1
                  heading:
                    type: string
                    example: 'New Announcement'
                  content:
                    type: string
                    example: 'This is for test purpose'
                  sending_rules:
                    type: string
                    example: all
                  expiry:
                    type: string
                    example: '2020-08-05'
      tags:
        - Announcements
      security: []
  /api/announcement/delete:
    post:
      summary: 'Delete Announcement'
      operationId: deleteAnnouncement
      description: "To delete an announcement, you need to use this request.\nReturns number of announcement deleted. (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '3 announcement(s) deleted '
                properties:
                  message:
                    type: string
                    example: '3 announcement(s) deleted '
      tags:
        - Announcements
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: array
                  description: 'All announcement IDs which needs to be deleted.'
                  example:
                    - 1
                    - 12
                    - 15
                  items:
                    type: string
              required:
                - delete_ids
      security: []
  /api/student/announcements:
    get:
      summary: 'Learner Announcement List'
      operationId: learnerAnnouncementList
      description: "Returns all the announcement in list format in paginated mode.\nYou can apply filter using search_param via heading of the announcements.\nThese annoucement list will appear in learner panel(dashboard) not admin panel."
      parameters:
        -
          in: query
          name: portalId
          description: 'Portal ID.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'Portal ID.'
            example: 1
        -
          in: query
          name: page_size
          description: 'Records per page.'
          example: 5
          required: true
          schema:
            type: integer
            description: 'Records per page.'
            example: 5
        -
          in: query
          name: page_number
          description: 'Page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'Page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'Order_by object.'
          example:
            colName: created_at
            direction: desc
          required: true
          schema:
            type: object
            description: 'Order_by object.'
            example:
              colName: created_at
              direction: desc
            properties: {  }
        -
          in: query
          name: search_param
          description: 'Search param object.'
          example:
            heading: ''
          required: true
          schema:
            type: object
            description: 'Search param object.'
            example:
              heading: ''
            properties: {  }
        -
          in: query
          name: viewType
          description: 'View type.'
          example: self
          required: true
          schema:
            type: string
            description: 'View type.'
            example: self
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  avatar: 'http://localhost:8000/storage/users/1/avatar.jpg'
                  recordsTotal: 100
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      heading: 'Announcement 1'
                      author: 'John Doe'
                      content: '<p>This is an example of announcement content</p>'
                      created_at: '21st Jan, 2020 12:00 PM'
                    -
                      id: 2
                      heading: 'Announcement 2'
                      author: 'John Doe'
                      content: '<p>This is an example of announcement content</p>'
                      created_at: '21st Jan, 2020 12:00 PM'
                properties:
                  avatar:
                    type: string
                    example: 'http://localhost:8000/storage/users/1/avatar.jpg'
                  recordsTotal:
                    type: integer
                    example: 100
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        heading: 'Announcement 1'
                        author: 'John Doe'
                        content: '<p>This is an example of announcement content</p>'
                        created_at: '21st Jan, 2020 12:00 PM'
                      -
                        id: 2
                        heading: 'Announcement 2'
                        author: 'John Doe'
                        content: '<p>This is an example of announcement content</p>'
                        created_at: '21st Jan, 2020 12:00 PM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        heading:
                          type: string
                          example: 'Announcement 1'
                        author:
                          type: string
                          example: 'John Doe'
                        content:
                          type: string
                          example: '<p>This is an example of announcement content</p>'
                        created_at:
                          type: string
                          example: '21st Jan, 2020 12:00 PM'
      tags:
        - Announcements
      security: []
  /api/modules/assignment:
    get:
      summary: 'Assignment Modules Tabular List'
      operationId: assignmentModulesTabularList
      description: "Returns all the assignment modules in a tabular list format in paginated mode.\nYou can apply filter using search_param via associatedCourse(modules used in course) and moduleName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'For searching items based on field names.'
          example: '{"associatedCourse":"","moduleName":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on field names.'
            example: '{"associatedCourse":"","moduleName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      name: Assignment-1
                      slug: assignment-1
                      type: assignment
                      submissionType: file
                      display_type: File
                      totalPoints: 20
                      icon: '<i class="el-icon-document"></i>'
                      author: 'Aom Staff'
                      created_at: 'Aug 03, 2020 09:56 AM'
                      showMappedCourses: false
                      course_count: 1
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: Assignment-1
                        slug: assignment-1
                        type: assignment
                        submissionType: file
                        display_type: File
                        totalPoints: 20
                        icon: '<i class="el-icon-document"></i>'
                        author: 'Aom Staff'
                        created_at: 'Aug 03, 2020 09:56 AM'
                        showMappedCourses: false
                        course_count: 1
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: Assignment-1
                        slug:
                          type: string
                          example: assignment-1
                        type:
                          type: string
                          example: assignment
                        submissionType:
                          type: string
                          example: file
                        display_type:
                          type: string
                          example: File
                        totalPoints:
                          type: integer
                          example: 20
                        icon:
                          type: string
                          example: '<i class="el-icon-document"></i>'
                        author:
                          type: string
                          example: 'Aom Staff'
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        showMappedCourses:
                          type: boolean
                          example: false
                        course_count:
                          type: integer
                          example: 1
      tags:
        - Assignments
      security: []
    post:
      summary: 'Create Assignment Module'
      operationId: createAssignmentModule
      description: "Handles the creation of an assignment module as part of course content.\nValidates the request and saves a new module with the given parameters."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 5
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 5
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - Assignments
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the assignment module.'
                  example: 'Essay on LMS'
                content:
                  type: string
                  description: 'Content for the assignment module.'
                  example: 'An introduction to LMS.'
                totalPoints:
                  type: integer
                  description: 'Points awarded for completing the assignment.'
                  example: 30
                submission_type:
                  type: string
                  description: 'Type of submission (text or file).'
                  example: file
                allowed_filetypes:
                  type: string
                  description: 'Required if submission type is file.'
                  example: '["pdf", "docx"]'
                isLocked:
                  type: boolean
                  description: 'Indicates if the module is locked.'
                  example: true
                estimatedCompletion:
                  type: nullable
                  description: 'Estimated time to complete the module.'
                  example: '90'
                estimationCompletedUnit:
                  type: nullable
                  description: 'Unit of time estimation (e.g., minutes, hours).'
                  example: minutes
              required:
                - name
                - content
                - submission_type
      security: []
  '/api/modules/assignment/{id}':
    put:
      summary: 'Update Assignment Module'
      operationId: updateAssignmentModule
      description: "Updates the details of a specified assignment module. (See parameters)\nAssignment modules can be used in the course as course content."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Module updated successfully'
      tags:
        - Assignments
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the assignment module.'
                  example: 'Getting Started'
                content:
                  type: string
                  description: 'Content for the assignment modules that students will see.'
                  example: '<p>This is the updated short content here</p>'
                totalPoints:
                  type: integer
                  description: 'Total points a student can get by completing this assignment.'
                  example: 20
                submission_type:
                  type: string
                  description: 'Type for the assignment module(file based or text based). Submission type options: text or file.'
                  example: file
                allowed_filetypes:
                  type: array
                  description: 'Allowed file types that will be submitted by the students when the submission_type is file.'
                  example:
                    - pdf
                    - docx
                  items:
                    type: string
                isLocked:
                  type: boolean
                  description: 'If true, the assignment is locked and students cannot submit it.'
                  example: true
                estimatedCompletion:
                  type: nullable
                  description: 'Estimated time to complete the module.'
                  example: '90'
                estimationCompletedUnit:
                  type: nullable
                  description: 'Unit of time estimation (e.g., minutes, hours).'
                  example: minutes
              required:
                - name
                - submission_type
                - allowed_filetypes
                - isLocked
      security: []
    get:
      summary: 'Retrieve Assignment Module'
      operationId: retrieveAssignmentModule
      description: "Retrieves the details of the specified assignment module using its ID. This includes\nthe module's ID, name, slug, content, total points, submission type, allowed file types,\nestimated completion, and associated courses. If the module's details exist, it fetches\nadditional information such as total points, submission type, lock status, and allowed\nfile types."
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\"id\": 1, \"name\": \"Assignment-1\", \"slug\": \"assignment-1\", \"content\": \"Content description\", \"totalPoints\": 100, \"submission_type\": \"file\", \"allowed_filetypes\": [\"image\", \"pdf\"], \"estimatedCompletion\": 5, \"estimationCompletedUnit\": hour,\n\"courses\": [{\"course_id\": 1, \"course_name\": \"Course Name\"}]}"
      tags:
        - Assignments
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'The ID of the assignment module to fetch details for.'
                  example: qui
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the assignment module.'
        example: '6'
        required: true
        schema:
          type: string
  /api/module/assignment/details:
    get:
      summary: 'Retrieve Detailed Assignment Module Info'
      operationId: retrieveDetailedAssignmentModuleInfo
      description: "Retrieves detailed information of an assignment module including course details, module details,\nand previous submissions. This function also checks if the module can be launched based on the\ncurrent registration and updates the module's status if accessed."
      parameters:
        -
          in: query
          name: portalId
          description: 'ID of the portal for which the assignment is being submitted.'
          example: 1
          required: false
          schema:
            type: integer
            description: 'ID of the portal for which the assignment is being submitted.'
            example: 1
        -
          in: query
          name: registrationId
          description: 'ID of the course registration to which the module is attached.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the course registration to which the module is attached.'
            example: '1'
        -
          in: query
          name: moduleId
          description: 'ID of the assignment module.'
          example: '4'
          required: true
          schema:
            type: string
            description: 'ID of the assignment module.'
            example: '4'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Assignment 1'
                  slug: assignment-1
                  content: '<p>Example content</p>'
                  courseName: 'Course 1'
                  courseSlug: 'http://localhost:8000/course/course-1'
                  min_time_spent: 120
                  totalPoints: 100
                  submissionType: file
                  maxUploadSize: 50
                  allowedFileTypes: '.pdf,.docx'
                  otherModules:
                    -
                      module_id: 1
                      name: test
                      slug: test
                      type: text
                      icon: '<i class="el-icon-tickets"></i>'
                      is_locked: false
                      lock_reason: ''
                      is_dripped: false
                      drip_message: ''
                      is_current: false
                      status_row_id: 1
                      status: Completed
                      started_on: '2020-08-03T10:02:33.000000Z'
                      completed_on: '2020-08-03T10:02:41.000000Z'
                      last_accessed_on: '8 hours ago'
                      total_time_spent:
                        hours: 0
                        minutes: 0
                        seconds: 6
                        totalSeconds: 6
                      completion_percentage: 100
                      no_of_times_accessed: 3
                    -
                      module_id: 4
                      name: assign
                      slug: assign
                      type: assignment
                      icon: '<i class="el-icon-edit-outline"></i>'
                      is_locked: false
                      lock_reason: ''
                      is_dripped: false
                      drip_message: ''
                      is_current: true
                      status_row_id: -1
                      status: 'Not Started'
                      started_on: ''
                      completed_on: ''
                      last_accessed_on: Never
                      total_time_spent: ''
                      points_awarded: ''
                      completion_percentage: 0
                      no_of_times_accessed: 0
                    -
                      module_id: 7
                      name: First-quiz
                      slug: first-quiz
                      type: quiz
                      icon: '<i class="el-icon-discover"></i>'
                      is_locked: false
                      lock_reason: ''
                      is_dripped: false
                      drip_message: ''
                      is_current: false
                      status_row_id: -1
                      status: 'Not Started'
                      started_on: ''
                      completed_on: ''
                      last_accessed_on: Never
                      total_time_spent: ''
                      points_awarded: ''
                      completion_percentage: 0
                      no_of_times_accessed: 0
                    -
                      module_id: 9
                      name: My-video-lesson
                      slug: my-video-lesson
                      type: video
                      icon: '<i class="el-icon-video-play"></i>'
                      is_locked: false
                      lock_reason: ''
                      is_dripped: false
                      drip_message: ''
                      is_current: false
                      status_row_id: 4
                      status: 'In Progress'
                      started_on: '2020-08-10T20:04:14.000000Z'
                      completed_on: null
                      last_accessed_on: '6 hours ago'
                      total_time_spent:
                        hours: 0
                        minutes: 0
                        seconds: 0
                        totalSeconds: null
                      completion_percentage: 0
                      no_of_times_accessed: 1
                    -
                      module_id: 10
                      name: 'Essay on LMS'
                      slug: essay-on-lms
                      type: assignment
                      icon: '<i class="el-icon-edit-outline"></i>'
                      is_locked: false
                      lock_reason: ''
                      is_dripped: false
                      drip_message: ''
                      is_current: false
                      status_row_id: 5
                      status: Completed
                      started_on: '2020-08-11T02:47:32.000000Z'
                      completed_on: '2020-08-11T02:47:32.000000Z'
                      last_accessed_on: '46 seconds ago'
                      total_time_spent:
                        hours: 0
                        minutes: 0
                        seconds: 0
                        totalSeconds: null
                      completion_percentage: 100
                      no_of_times_accessed: 1
                  launchCheck:
                    canbeLaunched: true
                    errTitle: ''
                    errDesc: ''
                  prevSlug: previous-assignment
                  nextSlug: next-assignment
                  status: 'In Progress'
                  display_status: 'In Progress'
                  statusRowId: 5
                  timeSpent: 30
                  prevSubmission: []
                  timeToBeSpent: 2
                properties:
                  name:
                    type: string
                    example: 'Assignment 1'
                  slug:
                    type: string
                    example: assignment-1
                  content:
                    type: string
                    example: '<p>Example content</p>'
                  courseName:
                    type: string
                    example: 'Course 1'
                  courseSlug:
                    type: string
                    example: 'http://localhost:8000/course/course-1'
                  min_time_spent:
                    type: integer
                    example: 120
                  totalPoints:
                    type: integer
                    example: 100
                  submissionType:
                    type: string
                    example: file
                  maxUploadSize:
                    type: integer
                    example: 50
                  allowedFileTypes:
                    type: string
                    example: '.pdf,.docx'
                  otherModules:
                    type: array
                    example:
                      -
                        module_id: 1
                        name: test
                        slug: test
                        type: text
                        icon: '<i class="el-icon-tickets"></i>'
                        is_locked: false
                        lock_reason: ''
                        is_dripped: false
                        drip_message: ''
                        is_current: false
                        status_row_id: 1
                        status: Completed
                        started_on: '2020-08-03T10:02:33.000000Z'
                        completed_on: '2020-08-03T10:02:41.000000Z'
                        last_accessed_on: '8 hours ago'
                        total_time_spent:
                          hours: 0
                          minutes: 0
                          seconds: 6
                          totalSeconds: 6
                        completion_percentage: 100
                        no_of_times_accessed: 3
                      -
                        module_id: 4
                        name: assign
                        slug: assign
                        type: assignment
                        icon: '<i class="el-icon-edit-outline"></i>'
                        is_locked: false
                        lock_reason: ''
                        is_dripped: false
                        drip_message: ''
                        is_current: true
                        status_row_id: -1
                        status: 'Not Started'
                        started_on: ''
                        completed_on: ''
                        last_accessed_on: Never
                        total_time_spent: ''
                        points_awarded: ''
                        completion_percentage: 0
                        no_of_times_accessed: 0
                      -
                        module_id: 7
                        name: First-quiz
                        slug: first-quiz
                        type: quiz
                        icon: '<i class="el-icon-discover"></i>'
                        is_locked: false
                        lock_reason: ''
                        is_dripped: false
                        drip_message: ''
                        is_current: false
                        status_row_id: -1
                        status: 'Not Started'
                        started_on: ''
                        completed_on: ''
                        last_accessed_on: Never
                        total_time_spent: ''
                        points_awarded: ''
                        completion_percentage: 0
                        no_of_times_accessed: 0
                      -
                        module_id: 9
                        name: My-video-lesson
                        slug: my-video-lesson
                        type: video
                        icon: '<i class="el-icon-video-play"></i>'
                        is_locked: false
                        lock_reason: ''
                        is_dripped: false
                        drip_message: ''
                        is_current: false
                        status_row_id: 4
                        status: 'In Progress'
                        started_on: '2020-08-10T20:04:14.000000Z'
                        completed_on: null
                        last_accessed_on: '6 hours ago'
                        total_time_spent:
                          hours: 0
                          minutes: 0
                          seconds: 0
                          totalSeconds: null
                        completion_percentage: 0
                        no_of_times_accessed: 1
                      -
                        module_id: 10
                        name: 'Essay on LMS'
                        slug: essay-on-lms
                        type: assignment
                        icon: '<i class="el-icon-edit-outline"></i>'
                        is_locked: false
                        lock_reason: ''
                        is_dripped: false
                        drip_message: ''
                        is_current: false
                        status_row_id: 5
                        status: Completed
                        started_on: '2020-08-11T02:47:32.000000Z'
                        completed_on: '2020-08-11T02:47:32.000000Z'
                        last_accessed_on: '46 seconds ago'
                        total_time_spent:
                          hours: 0
                          minutes: 0
                          seconds: 0
                          totalSeconds: null
                        completion_percentage: 100
                        no_of_times_accessed: 1
                    items:
                      type: object
                      properties:
                        module_id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: test
                        slug:
                          type: string
                          example: test
                        type:
                          type: string
                          example: text
                        icon:
                          type: string
                          example: '<i class="el-icon-tickets"></i>'
                        is_locked:
                          type: boolean
                          example: false
                        lock_reason:
                          type: string
                          example: ''
                        is_dripped:
                          type: boolean
                          example: false
                        drip_message:
                          type: string
                          example: ''
                        is_current:
                          type: boolean
                          example: false
                        status_row_id:
                          type: integer
                          example: 1
                        status:
                          type: string
                          example: Completed
                        started_on:
                          type: string
                          example: '2020-08-03T10:02:33.000000Z'
                        completed_on:
                          type: string
                          example: '2020-08-03T10:02:41.000000Z'
                        last_accessed_on:
                          type: string
                          example: '8 hours ago'
                        total_time_spent:
                          type: object
                          properties:
                            hours:
                              type: integer
                              example: 0
                            minutes:
                              type: integer
                              example: 0
                            seconds:
                              type: integer
                              example: 6
                            totalSeconds:
                              type: integer
                              example: 6
                        completion_percentage:
                          type: integer
                          example: 100
                        no_of_times_accessed:
                          type: integer
                          example: 3
                  launchCheck:
                    type: object
                    properties:
                      canbeLaunched:
                        type: boolean
                        example: true
                      errTitle:
                        type: string
                        example: ''
                      errDesc:
                        type: string
                        example: ''
                  prevSlug:
                    type: string
                    example: previous-assignment
                  nextSlug:
                    type: string
                    example: next-assignment
                  status:
                    type: string
                    example: 'In Progress'
                  display_status:
                    type: string
                    example: 'In Progress'
                  statusRowId:
                    type: integer
                    example: 5
                  timeSpent:
                    type: integer
                    example: 30
                  prevSubmission:
                    type: array
                    example: []
                  timeToBeSpent:
                    type: integer
                    example: 2
      tags:
        - Assignments
      security: []
  /api/module/assignment/submissions:
    get:
      summary: 'Retrieve Assignment Submission Details'
      operationId: retrieveAssignmentSubmissionDetails
      description: 'Retrieves the submission details of the assigment the student have given. Helps in grading a student. (See Response)'
      parameters:
        -
          in: query
          name: statusRowId
          description: 'ID of the Module status of the current assignment.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the Module status of the current assignment.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  courseId: 1
                  courseName: 'course 1'
                  assignmentName: assign
                  status: 'In Progress'
                  content: Desc
                  totalPoints: 50
                  userFullName: 'Aom Staff'
                  userEmail: aomstaff@staff.com
                  submissions:
                    -
                      id: 1
                      file_path:
                        - aom-uploads-test.s3.us-west-2.amazonaws.com/assignments/aom-sample-bulkupload_1597042007.csv
                      student_message: null
                      instructor_message: null
                      points_awarded: null
                      evaluated_by: ''
                      submitted_on: 'Aug 10, 2020 11:33 AM'
                      evaluated_on: ''
                properties:
                  courseId:
                    type: integer
                    example: 1
                  courseName:
                    type: string
                    example: 'course 1'
                  assignmentName:
                    type: string
                    example: assign
                  status:
                    type: string
                    example: 'In Progress'
                  content:
                    type: string
                    example: Desc
                  totalPoints:
                    type: integer
                    example: 50
                  userFullName:
                    type: string
                    example: 'Aom Staff'
                  userEmail:
                    type: string
                    example: aomstaff@staff.com
                  submissions:
                    type: array
                    example:
                      -
                        id: 1
                        file_path:
                          - aom-uploads-test.s3.us-west-2.amazonaws.com/assignments/aom-sample-bulkupload_1597042007.csv
                        student_message: null
                        instructor_message: null
                        points_awarded: null
                        evaluated_by: ''
                        submitted_on: 'Aug 10, 2020 11:33 AM'
                        evaluated_on: ''
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        file_path:
                          type: array
                          example:
                            - aom-uploads-test.s3.us-west-2.amazonaws.com/assignments/aom-sample-bulkupload_1597042007.csv
                          items:
                            type: string
                        student_message:
                          type: string
                          example: null
                        instructor_message:
                          type: string
                          example: null
                        points_awarded:
                          type: string
                          example: null
                        evaluated_by:
                          type: string
                          example: ''
                        submitted_on:
                          type: string
                          example: 'Aug 10, 2020 11:33 AM'
                        evaluated_on:
                          type: string
                          example: ''
      tags:
        - Assignments
      security: []
  /api/module/assignment/submit:
    post:
      summary: 'Submit Assignment'
      operationId: submitAssignment
      description: "Submits the assignment after attempting all the aspects of the assignment.Updates the status of assignment to submitted if student is finished the assignment and submits.\n(See Parameters)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Assignment submitted successfully'
                properties:
                  message:
                    type: string
                    example: 'Assignment submitted successfully'
      tags:
        - Assignments
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'ID of the portal for which the assignment is being submitted.'
                  example: 1
                statusRowId:
                  type: required
                  description: 'ID of the Module status of the current assignment.'
                  example: '7'
                submissions:
                  type: required
                  description: 'Submission data(file or text).'
                  example: '[1,2,3]'
                studentMessage:
                  type: required
                  description: 'Student message to instructor.'
                  example: '"This is my assignment submission"'
      security: []
  /api/module/assignment/upload:
    post:
      summary: 'Upload Assignment File'
      operationId: uploadAssignmentFile
      description: 'Handles the upload of an assignment file by students. You can use File form to upload a file to the system.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  s3_url: 'https://s3.aws.com/wTsycTYRCLKIUVXXIYFYVXBXIXUGIXB'
                properties:
                  s3_url:
                    type: string
                    example: 'https://s3.aws.com/wTsycTYRCLKIUVXXIYFYVXBXIXUGIXB'
      tags:
        - Assignments
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                file:
                  type: string
                  description: 'File to be uploaded for current assignment.'
                  example: aliquam
              required:
                - file
      security: []
  /api/module/assignment/evaluate:
    post:
      summary: 'Evaluate Assignment'
      operationId: evaluateAssignment
      description: "Evaluates the assignment from Instructor side.Updates the status of assignment to completed if Instructor thinks student's submission is upto the marks.\n(See Parameters)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Assignment evaluated successfully'
                properties:
                  message:
                    type: string
                    example: 'Assignment evaluated successfully'
      tags:
        - Assignments
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'ID of the portal for which the assignment is being submitted.'
                  example: 1
                statusRowId:
                  type: required
                  description: 'ID of the Module status of the current assignment.'
                  example: '7'
                evaluation:
                  type: required
                  description: 'Evaluation data by the Instructor(Completed or not).'
                  example: "{instructorMessage : 'You comments look good', pointsAwarded: '50', isAccepted : true }"
      security: []
  /api/audit-activities:
    get:
      summary: 'Get Audit Activities'
      operationId: getAuditActivities
      description: "Fetches and paginates a list of audit log activities for the selected portal and date range.\nSupports filtering by user, activity type, date range, and model (performedOn). Also allows sorting."
      parameters:
        -
          in: query
          name: portalId
          description: 'optional Filter activities based on a specific portal and its sub-portals.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'optional Filter activities based on a specific portal and its sub-portals.'
            example: 5
        -
          in: query
          name: page_size
          description: 'Number of records per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'Number of records per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The current page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'optional Sorting details as a JSON object with `colName` and `direction`.'
          example:
            colName: created_at
            direction: desc
          required: false
          schema:
            type: object
            description: 'optional Sorting details as a JSON object with `colName` and `direction`.'
            example:
              colName: created_at
              direction: desc
            properties: {  }
        -
          in: query
          name: search_param
          description: 'optional JSON-encoded object containing search filters (user_id, activityName, dates, performedOn).'
          example: '{"user_id":3,"activityName":"created","dates":["2024-12-01","2024-12-31"],"performedOn":"Course"}'
          required: false
          schema:
            type: string
            description: 'optional JSON-encoded object containing search filters (user_id, activityName, dates, performedOn).'
            example: '{"user_id":3,"activityName":"created","dates":["2024-12-01","2024-12-31"],"performedOn":"Course"}'
        -
          in: query
          name: context
          description: 'optional Custom context passed from frontend (not used internally).'
          example: admin
          required: false
          schema:
            type: string
            description: 'optional Custom context passed from frontend (not used internally).'
            example: admin
        -
          in: query
          name: selectedMonth
          description: 'The selected month (in m-Y format) used to determine the date range for filtering.'
          example: 03-2024
          required: true
          schema:
            type: string
            description: 'The selected month (in m-Y format) used to determine the date range for filtering.'
            example: 03-2024
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 135
                  recordsFiltered: 23
                  records:
                    -
                      performed_by: 'Jane Doe'
                      effect_on: Course
                      subject: 'Course: Laravel Basics'
                      action: CREATED
                      created_at: '13 Apr 2025 02:45 PM'
                      details:
                        attributes:
                          name: 'Laravel Basics'
                          status: active
                  performedOnList:
                    - Course
                    - Module
                    - User
                properties:
                  recordsTotal:
                    type: integer
                    example: 135
                  recordsFiltered:
                    type: integer
                    example: 23
                  records:
                    type: array
                    example:
                      -
                        performed_by: 'Jane Doe'
                        effect_on: Course
                        subject: 'Course: Laravel Basics'
                        action: CREATED
                        created_at: '13 Apr 2025 02:45 PM'
                        details:
                          attributes:
                            name: 'Laravel Basics'
                            status: active
                    items:
                      type: object
                      properties:
                        performed_by:
                          type: string
                          example: 'Jane Doe'
                        effect_on:
                          type: string
                          example: Course
                        subject:
                          type: string
                          example: 'Course: Laravel Basics'
                        action:
                          type: string
                          example: CREATED
                        created_at:
                          type: string
                          example: '13 Apr 2025 02:45 PM'
                        details:
                          type: object
                          properties:
                            attributes:
                              type: object
                              properties:
                                name:
                                  type: string
                                  example: 'Laravel Basics'
                                status:
                                  type: string
                                  example: active
                  performedOnList:
                    type: array
                    example:
                      - Course
                      - Module
                      - User
                    items:
                      type: string
      tags:
        - 'Audit Logs'
      security: []
  /api/audit-activities/verb/lookup:
    get:
      summary: 'Audit Activity Lookup'
      operationId: auditActivityLookup
      description: "Retrieves all the activities performed by the user. This is a lookup request\nthat helps in showing options in dropdowns elements."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: login
                    display_value: LOGIN
                  -
                    db_value: created
                    display_value: CREATED
                  -
                    db_value: updated
                    display_value: UPDATED
                  -
                    db_value: deleted
                    display_value: DELETED
      tags:
        - 'Audit Logs'
      security: []
  /api/badges/tabularlist:
    get:
      summary: 'Get a tabular list of badges, with pagination and search'
      operationId: getATabularListOfBadgesWithPaginationAndSearch
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'Number of records to return per page.'
          example: 50
          required: false
          schema:
            type: integer
            description: 'Number of records to return per page.'
            example: 50
        -
          in: query
          name: page_number
          description: 'Page number to return.'
          example: 1
          required: false
          schema:
            type: integer
            description: 'Page number to return.'
            example: 1
        -
          in: query
          name: order_by
          description: "Sort the results by the given column and direction. e.g. {colName: 'title', direction: 'asc'}"
          example: []
          required: false
          schema:
            type: object
            description: "Sort the results by the given column and direction. e.g. {colName: 'title', direction: 'asc'}"
            example: []
            properties: {  }
        -
          in: query
          name: search_param
          description: "Search for records with the given parameters. e.g. {title: 'test'}"
          example: []
          required: false
          schema:
            type: object
            description: "Search for records with the given parameters. e.g. {title: 'test'}"
            example: []
            properties: {  }
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      title: 'Badge 1'
                      badgeIconUrl: 'https://example.com/badge1.png'
                      points: 10
                    -
                      id: 2
                      title: 'Badge 2'
                      badgeIconUrl: 'https://example.com/badge2.png'
                      points: 20
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        title: 'Badge 1'
                        badgeIconUrl: 'https://example.com/badge1.png'
                        points: 10
                      -
                        id: 2
                        title: 'Badge 2'
                        badgeIconUrl: 'https://example.com/badge2.png'
                        points: 20
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: 'Badge 1'
                        badgeIconUrl:
                          type: string
                          example: 'https://example.com/badge1.png'
                        points:
                          type: integer
                          example: 10
      tags:
        - Badge
      security: []
  /api/badge/create:
    post:
      summary: 'Create a new badge'
      operationId: createANewBadge
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 3
                  message: 'Badge created successfully'
                properties:
                  id:
                    type: integer
                    example: 3
                  message:
                    type: string
                    example: 'Badge created successfully'
      tags:
        - Badge
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                title:
                  type: required
                  description: 'string The title of the badge.'
                  example: Gold
                points:
                  type: required
                  description: 'numeric The number of points the badge is worth.'
                  example: '1'
                badgeIconUrl:
                  type: required
                  description: 'string The URL of the icon for the badge.'
                  example: /images/badges/Badge_1.png
                defaultIconUrl:
                  type: nullable
                  description: 'string The default icon URL to use if the badgeIconUrl is not available.'
                  example: /images/default-badge.png
                organizationId:
                  type: nullable
                  description: 'string The ID of the organization the badge belongs to.'
                  example: '97852067'
      security: []
  /api/badges/defaultBadgeLookUp:
    get:
      summary: 'Return default badges available in the system.'
      operationId: returnDefaultBadgesAvailableInTheSystem
      description: 'These badges are not stored in the database and are available for use as soon as the application is installed.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  value: 'Badge 1'
                  url: /images/badges/Badge_1.png
                properties:
                  value:
                    type: string
                    example: 'Badge 1'
                  url:
                    type: string
                    example: /images/badges/Badge_1.png
      tags:
        - Badge
      security: []
  '/api/badge/{id}':
    get:
      summary: 'Retrieve a badge by its ID.'
      operationId: retrieveABadgeByItsID
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  title: Gold
                  points: 1
                  organizationId: '97852067'
                  badgeIconUrl: /images/badges/Badge_1.png
                properties:
                  id:
                    type: integer
                    example: 1
                  title:
                    type: string
                    example: Gold
                  points:
                    type: integer
                    example: 1
                  organizationId:
                    type: string
                    example: '97852067'
                  badgeIconUrl:
                    type: string
                    example: /images/badges/Badge_1.png
      tags:
        - Badge
      security: []
    put:
      summary: 'Update an existing badge by its ID.'
      operationId: updateAnExistingBadgeByItsID
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Badge updated successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Badge updated successfully'
      tags:
        - Badge
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                title:
                  type: required
                  description: 'string The title of the badge.'
                  example: Gold
                points:
                  type: nullable
                  description: 'numeric The number of points the badge is worth.'
                  example: '1'
                badgeIconUrl:
                  type: required
                  description: 'string The URL of the icon for the badge.'
                  example: /images/badges/Badge_1.png
                defaultIconUrl:
                  type: nullable
                  description: 'string The default icon URL to use if the badgeIconUrl is not available.'
                  example: /images/default-badge.png
                organizationId:
                  type: nullable
                  description: 'string The ID of the organization the badge belongs to.'
                  example: '97852067'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the badge needs to be retrieved.'
        example: '1'
        required: true
        schema:
          type: string
  /api/badge/delete:
    post:
      summary: 'Delete specified badges.'
      operationId: deleteSpecifiedBadges
      description: "Deletes badges that are not assigned to any users and not used in gamification events.\nLogs an activity for each deleted badge."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '1 badge(s) deleted. 0 badge(s) not deleted as they are assigned to users. 0 badge(s) not deleted as they are used in gamification events.'
                properties:
                  message:
                    type: string
                    example: '1 badge(s) deleted. 0 badge(s) not deleted as they are assigned to users. 0 badge(s) not deleted as they are used in gamification events.'
      tags:
        - Badge
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: array
                  description: 'An array of badge IDs to be deleted. The IDs must have permission to be deleted.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - delete_ids
      security: []
  /api/categories/product/lookup:
    get:
      summary: 'Product Category Lookup'
      operationId: productCategoryLookup
      description: "Retrieves all the product categories.\nThis request helps in showing all product categories in form elements like dropdown, etc.\nReturns ID and name of the product category."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'Product Category 1'
      tags:
        - Categories
      security: []
  /api/categories/course/lookup:
    get:
      summary: 'Course Category Lookup'
      operationId: courseCategoryLookup
      description: "Retrieves all categories of the courses. If courseIds is provided, it will filter the categories for those courses.\nIf categoryIds is provided, it will filter the categories with those IDs.\nReturns name and id of the category."
      parameters:
        -
          in: query
          name: array
          description: 'categoryIds The IDs of the categories to filter.'
          example: '[1,2]'
          required: false
          schema:
            type: string
            description: 'categoryIds The IDs of the categories to filter.'
            example: '[1,2]'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'Category 1'
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'Category 1'
      tags:
        - Categories
      security: []
  /api/categories/module/lookup:
    get:
      summary: 'Module Category Lookup'
      operationId: moduleCategoryLookup
      description: "Retrieves all categories of the modules.\nReturns name and id of the category."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'Category 1'
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'Category 1'
      tags:
        - Categories
      security: []
  /api/categories/question/lookup:
    get:
      summary: 'Question Category Lookup'
      operationId: questionCategoryLookup
      description: "Retrieves all the categories of the questions user has ever created.\nThis request helps in showing all question categories in form elements like dropdown, etc.\nReturns ID and name of the question category."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 4
                    name: Question-cat
      tags:
        - Categories
      security: []
  /api/categories/user/lookup:
    get:
      summary: 'User Category Lookup'
      operationId: userCategoryLookup
      description: "Retrieves all the categories of the users user has ever created.\nThis request helps in showing all user categories in form elements like dropdown, etc.\nReturns ID and name of the user category."
      parameters:
        -
          in: query
          name: search_term
          description: 'optional The name or substring of the user category name to search for that user category. example: user'
          example: numquam
          required: false
          schema:
            type: string
            description: 'optional The name or substring of the user category name to search for that user category. example: user'
            example: numquam
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'User Category 1'
      tags:
        - Categories
      security: []
  /api/categories/learning-path/lookup:
    get:
      summary: 'Learning Path Category Lookup'
      operationId: learningPathCategoryLookup
      description: "Retrieves all the categories of the learning paths user has ever created.\nThis request helps in showing all learning path categories in form elements like dropdown, etc.\nReturns ID and name of the learning path category."
      parameters:
        -
          in: query
          name: search_term
          description: 'optional The name or substring of the learning path category name to search for that learning path category. example: learning'
          example: sed
          required: false
          schema:
            type: string
            description: 'optional The name or substring of the learning path category name to search for that learning path category. example: learning'
            example: sed
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'Learning Path Category 1'
      tags:
        - Categories
      security: []
  /api/coursecategory/tabularlist:
    get:
      summary: 'Course Category Tabular List'
      operationId: courseCategoryTabularList
      description: "Returns all the course categories in a tabular list format in paginated mode.\nYou can apply filter using search_param via categoryName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '9'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '9'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'For searching items based on category name.'
          example: '{"categoryName":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on category name.'
            example: '{"categoryName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 4
                  recordsFiltered: 3
                  records:
                    -
                      id: 3
                      name: superman_postman
                      author: 'Client Admin'
                      count: 0
                      created_at: 'Aug 10, 2020 12:43 PM'
                    -
                      id: 2
                      name: category-new
                      author: 'Aom Staff'
                      count: 0
                      created_at: 'Aug 10, 2020 12:37 PM'
                    -
                      id: 1
                      name: Category-1
                      author: 'Aom Staff'
                      count: 1
                      created_at: 'Aug 09, 2020 06:20 PM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 4
                  recordsFiltered:
                    type: integer
                    example: 3
                  records:
                    type: array
                    example:
                      -
                        id: 3
                        name: superman_postman
                        author: 'Client Admin'
                        count: 0
                        created_at: 'Aug 10, 2020 12:43 PM'
                      -
                        id: 2
                        name: category-new
                        author: 'Aom Staff'
                        count: 0
                        created_at: 'Aug 10, 2020 12:37 PM'
                      -
                        id: 1
                        name: Category-1
                        author: 'Aom Staff'
                        count: 1
                        created_at: 'Aug 09, 2020 06:20 PM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 3
                        name:
                          type: string
                          example: superman_postman
                        author:
                          type: string
                          example: 'Client Admin'
                        count:
                          type: integer
                          example: 0
                        created_at:
                          type: string
                          example: 'Aug 10, 2020 12:43 PM'
      tags:
        - Categories
      security: []
  /api/modulecategory/tabularlist:
    get:
      summary: 'Module Category Tabular List'
      operationId: moduleCategoryTabularList
      description: "Returns all the module categories in a tabular list format in paginated mode.\nYou can apply a filter using search_param via categoryName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '9'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '9'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'For searching items based on category name.'
          example: '{"categoryName":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on category name.'
            example: '{"categoryName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 4
                  recordsFiltered: 2
                  records:
                    -
                      id: 1
                      name: module-category-1
                      author: 'Aom Staff'
                      count: 3
                      created_at: 'Aug 10, 2020 12:43 PM'
                    -
                      id: 2
                      name: module-category-2
                      author: 'Client Admin'
                      count: 1
                      created_at: 'Aug 09, 2020 06:20 PM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 4
                  recordsFiltered:
                    type: integer
                    example: 2
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: module-category-1
                        author: 'Aom Staff'
                        count: 3
                        created_at: 'Aug 10, 2020 12:43 PM'
                      -
                        id: 2
                        name: module-category-2
                        author: 'Client Admin'
                        count: 1
                        created_at: 'Aug 09, 2020 06:20 PM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: module-category-1
                        author:
                          type: string
                          example: 'Aom Staff'
                        count:
                          type: integer
                          example: 3
                        created_at:
                          type: string
                          example: 'Aug 10, 2020 12:43 PM'
      tags:
        - Categories
      security: []
  /api/productcategory/tabularlist:
    get:
      summary: 'Product Category Tabular List'
      operationId: productCategoryTabularList
      description: "Returns all the product categories in a tabular list format in paginated mode.\nYou can apply a filter using search_param via categoryName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '9'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '9'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'For searching items based on category name.'
          example: '{"categoryName":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on category name.'
            example: '{"categoryName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 2
                  recordsFiltered: 1
                  records:
                    -
                      id: 2
                      name: 'product memberships'
                      author: 'Aom Staff'
                      count: 1
                      created_at: 'May 10, 2022 03:39 AM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 2
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 2
                        name: 'product memberships'
                        author: 'Aom Staff'
                        count: 1
                        created_at: 'May 10, 2022 03:39 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 2
                        name:
                          type: string
                          example: 'product memberships'
                        author:
                          type: string
                          example: 'Aom Staff'
                        count:
                          type: integer
                          example: 1
                        created_at:
                          type: string
                          example: 'May 10, 2022 03:39 AM'
      tags:
        - Categories
      security: []
  /api/questioncategory/tabularlist:
    get:
      summary: 'Question Category Tabular List'
      operationId: questionCategoryTabularList
      description: "Returns all the question categories in a tabular list format in paginated mode.\nYou can apply filter using search_param via categoryName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'For searching items based on field names.'
          example: '{"categoryName":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on field names.'
            example: '{"categoryName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 3
                  recordsFiltered: 3
                  records:
                    -
                      id: 1
                      name: 'Question Category-1'
                      author: 'Aom Staff'
                      count: 4
                      created_at: 'Aug 10, 2020 12:43 PM'
                    -
                      id: 2
                      name: 'Question Category-2'
                      author: 'Client Admin'
                      count: 2
                      created_at: 'Aug 09, 2020 06:20 PM'
                    -
                      id: 3
                      name: 'Question Category-3'
                      author: 'Aom Staff'
                      count: 1
                      created_at: 'Aug 10, 2020 06:34 PM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 3
                  recordsFiltered:
                    type: integer
                    example: 3
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Question Category-1'
                        author: 'Aom Staff'
                        count: 4
                        created_at: 'Aug 10, 2020 12:43 PM'
                      -
                        id: 2
                        name: 'Question Category-2'
                        author: 'Client Admin'
                        count: 2
                        created_at: 'Aug 09, 2020 06:20 PM'
                      -
                        id: 3
                        name: 'Question Category-3'
                        author: 'Aom Staff'
                        count: 1
                        created_at: 'Aug 10, 2020 06:34 PM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Question Category-1'
                        author:
                          type: string
                          example: 'Aom Staff'
                        count:
                          type: integer
                          example: 4
                        created_at:
                          type: string
                          example: 'Aug 10, 2020 12:43 PM'
      tags:
        - Categories
      security: []
  /api/category/create:
    post:
      summary: 'Create Category'
      operationId: createCategory
      description: "Creates a new category using parameters mentioned. (See parameters)\nCreates the course/question/product category details using category name and category type."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Category Created Successfully'
                properties:
                  message:
                    type: string
                    example: 'Category Created Successfully'
      tags:
        - Categories
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                category_name:
                  type: string
                  description: 'Name of the category.'
                  example: category-new
                categoryType:
                  type: string
                  description: 'Type of the category to be created.'
                  example: course
              required:
                - category_name
                - categoryType
      security: []
  '/api/category/{id}':
    put:
      summary: 'Update Category'
      operationId: updateCategory
      description: "Updates a category using parameters mentioned. (See parameters)\nUpdates the course/question/product category details using category name and category type."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Category Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Category Updated Successfully'
      tags:
        - Categories
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                category_name:
                  type: string
                  description: 'Name of the category.'
                  example: category-new
                categoryType:
                  type: string
                  description: 'Type of the category to be updated.'
                  example: course
              required:
                - category_name
                - categoryType
      security: []
    get:
      summary: 'Get Category'
      operationId: getCategory
      description: 'Retrieves a category by its ID.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 3
                  name: superman_postman
                  type: course
                  created_by: 2
                  updated_by: null
                  deleted_by: null
                  created_at: '2020-08-10 12:43:12'
                  updated_at: '2020-08-10 12:56:37'
                  deleted_at: null
                properties:
                  id:
                    type: integer
                    example: 3
                  name:
                    type: string
                    example: superman_postman
                  type:
                    type: string
                    example: course
                  created_by:
                    type: integer
                    example: 2
                  updated_by:
                    type: string
                    example: null
                  deleted_by:
                    type: string
                    example: null
                  created_at:
                    type: string
                    example: '2020-08-10 12:43:12'
                  updated_at:
                    type: string
                    example: '2020-08-10 12:56:37'
                  deleted_at:
                    type: string
                    example: null
      tags:
        - Categories
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the category.'
        example: '3'
        required: true
        schema:
          type: string
  /api/category/delete:
    post:
      summary: 'Delete categories of given type'
      operationId: deleteCategoriesOfGivenType
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '3 category(s) deleted. 2 category(s) not deleted as it is used in dynamic quiz(s). Please remove the category from the quiz and try again.'
                  deletedCategories:
                    - 4
                  notDeletedCategories:
                    - 1
                    - 2
                  usedInPlaces:
                    -
                      'Question Category-1':
                        -
                          id: 1
                          name: 'Quiz Name 1'
                        -
                          id: 2
                          name: 'Quiz Name 2'
                    -
                      'Question Category-2':
                        -
                          id: 3
                          name: 'Quiz Name 3'
                properties:
                  message:
                    type: string
                    example: '3 category(s) deleted. 2 category(s) not deleted as it is used in dynamic quiz(s). Please remove the category from the quiz and try again.'
                  deletedCategories:
                    type: array
                    example:
                      - 4
                    items:
                      type: integer
                  notDeletedCategories:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  usedInPlaces:
                    type: array
                    example:
                      -
                        'Question Category-1':
                          -
                            id: 1
                            name: 'Quiz Name 1'
                          -
                            id: 2
                            name: 'Quiz Name 2'
                      -
                        'Question Category-2':
                          -
                            id: 3
                            name: 'Quiz Name 3'
                    items:
                      type: object
                      properties:
                        'Question Category-1':
                          type: array
                          example:
                            -
                              id: 1
                              name: 'Quiz Name 1'
                            -
                              id: 2
                              name: 'Quiz Name 2'
                          items:
                            type: object
                            properties:
                              id:
                                type: integer
                                example: 1
                              name:
                                type: string
                                example: 'Quiz Name 1'
      tags:
        - Categories
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                type:
                  type: required
                  description: 'Type of category to be deleted.'
                  example: question
                delete_ids:
                  type: required
                  description: 'Ids of categories to be deleted.'
                  example: '[1,2,3]'
                categoryName:
                  type: required
                  description: 'Name of category to be deleted.'
                  example: 'Question Category-1'
      security: []
  /api/categories/question-count:
    get:
      summary: 'Get the count of questions in a category'
      operationId: getTheCountOfQuestionsInACategory
      description: 'Get the count of questions in a category.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  questionCount: 10
                properties:
                  questionCount:
                    type: integer
                    example: 10
      tags:
        - Categories
      security: []
    parameters:
      -
        in: path
        name: categoryId
        description: 'The category id.'
        example: '1'
        required: true
        schema:
          type: string
  /api/learning-pathcategory/tabularlist:
    get:
      summary: 'Learning Path Category Tabular List'
      operationId: learningPathCategoryTabularList
      description: "Returns all the learning path categories in a tabular list format in paginated mode.\nYou can apply a filter using search_param via categoryName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the item you want for a page.'
          example: '9'
          required: true
          schema:
            type: string
            description: 'The number of the item you want for a page.'
            example: '9'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'For searching items based on category name.'
          example: '{"categoryName":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on category name.'
            example: '{"categoryName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      name: 'learning path category 1'
                      author: 'Aom Staff'
                      count: 1
                      created_at: 'May 16, 2022 07:00 AM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'learning path category 1'
                        author: 'Aom Staff'
                        count: 1
                        created_at: 'May 16, 2022 07:00 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'learning path category 1'
                        author:
                          type: string
                          example: 'Aom Staff'
                        count:
                          type: integer
                          example: 1
                        created_at:
                          type: string
                          example: 'May 16, 2022 07:00 AM'
      tags:
        - Categories
      security: []
  /api/certificate_templates/lookup:
    get:
      summary: 'Certificate Template Lookup'
      operationId: certificateTemplateLookup
      description: 'Returns all the certificate templates in a list format.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'cert 1'
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'cert 1'
      tags:
        - 'Certificate Templates'
      security: []
  /api/certificate_templates/tabularlist:
    get:
      summary: 'Certificate Template Tabular List'
      operationId: certificateTemplateTabularList
      description: "Returns all the certificate templates in a tabular list format in paginated mode.\nYou can apply filter using search_param via templateName(certificate template name) and courseId(course Id)."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the item you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the item you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'For searching items based on Course category ids, course name.'
          example: '{"templateName":"abc","courseId":"1"}'
          required: false
          schema:
            type: string
            description: 'For searching items based on Course category ids, course name.'
            example: '{"templateName":"abc","courseId":"1"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      name: 'cert 1'
                      slug: cert-1
                      status: publish
                      categories: ''
                      author: 'Aom Staff'
                      created_at: '03 Aug 2020 09:08 AM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'cert 1'
                        slug: cert-1
                        status: publish
                        categories: ''
                        author: 'Aom Staff'
                        created_at: '03 Aug 2020 09:08 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'cert 1'
                        slug:
                          type: string
                          example: cert-1
                        status:
                          type: string
                          example: publish
                        categories:
                          type: string
                          example: ''
                        author:
                          type: string
                          example: 'Aom Staff'
                        created_at:
                          type: string
                          example: '03 Aug 2020 09:08 AM'
      tags:
        - 'Certificate Templates'
      security: []
  /api/certificate_templates/quickEdit:
    post:
      summary: 'Quick Edit Certificate Templates'
      operationId: quickEditCertificateTemplates
      description: 'Updates the instructor/author for the selected certificate templates.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Certificate Templates updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Certificate Templates updated Successfully'
      tags:
        - 'Certificate Templates'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                template_ids:
                  type: required
                  description: 'array The list of ids of the certificate templates you want to perform the action on.'
                  example: explicabo
                author_id:
                  type: required
                  description: 'integer The ID of the new instructor/author.'
                  example: commodi
      security: []
  /api/certificate_template/keysLookup:
    get:
      summary: 'Field Keys Lookup'
      operationId: fieldKeysLookup
      description: "Retrieves all the fields that can be available on the certificate template.\nHelps while showing fields in form elements like dropdown while creating certificate template.\nReturns a list of all fields that can be used on the certificate template. (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: student_first_name
                    display_value: 'Student First Name'
                  -
                    db_value: student_last_name
                    display_value: 'Student Last Name'
                  -
                    db_value: student_full_name
                    display_value: 'Student Full Name'
                  -
                    db_value: course_name
                    display_value: 'Course Name'
                  -
                    db_value: issue_date
                    display_value: 'Date of Issue'
                  -
                    db_value: expiry_date
                    display_value: 'Date of Expiry'
                  -
                    db_value: instructor_name
                    display_value: 'Instructor Name'
                  -
                    db_value: certificate_code
                    display_value: 'Certificate Code'
                  -
                    db_value: course_credit
                    display_value: 'Course Credit'
                  -
                    db_value: learning_path_name
                    display_value: 'Learning Path Name'
                  -
                    db_value: learning_path_credit
                    display_value: 'Learning Path Credit'
                  -
                    db_value: custom_text
                    display_value: 'Custom Text'
      tags:
        - 'Certificate Templates'
      security: []
  /api/certificate_template/fontFamilyLookup:
    get:
      summary: 'Font Families Lookup'
      operationId: fontFamiliesLookup
      description: "Retrieves all the font families that can be used on the certificate template.\nHelps while showing font families in form elements like dropdown while creating certificate template.\nReturns a list of all font families that can be used on the certificate template. (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: Lato
                    display_value: Arial
                    is_selected: 'true'
                  -
                    db_value: Courier
                    display_value: Courier
                  -
                    db_value: 'Source Sans Pro'
                    display_value: Helvetica
                  -
                    db_value: Montserrat
                    display_value: Montserrat
                  -
                    db_value: 'Roboto Condensed'
                    display_value: Roboto
                  -
                    db_value: 'Space Mono'
                    display_value: 'Space Mono'
                  -
                    db_value: 'Roboto Slab'
                    display_value: 'Roboto Slab'
      tags:
        - 'Certificate Templates'
      security: []
  /api/certificate_template:
    post:
      summary: 'Create Certificate Template'
      operationId: createCertificateTemplate
      description: 'Creates a new certificate template and stores it in the database. The template can be used to assign to students upon course completion.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 2
                  message: 'Certificate Template created successfully'
                properties:
                  id:
                    type: integer
                    example: 2
                  message:
                    type: string
                    example: 'Certificate Template created successfully'
      tags:
        - 'Certificate Templates'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'The name of the certificate template.'
                  example: Completion-Certificate
                organization_id:
                  type: integer
                  description: 'optional The ID of the organization associated with the certificate template.'
                  example: 12
                bg_url:
                  type: string
                  description: 'optional The URL of the background image for the certificate template.'
                  example: 'http://aom.com/images/default-certificate.png'
                height:
                  type: integer
                  description: 'The height of the certificate template.'
                  example: 680
                width:
                  type: integer
                  description: 'The width of the certificate template.'
                  example: 1075
                fields:
                  type: array
                  description: 'The array of fields to be included in the certificate. Each field contains its properties like key, font size, font family, etc.'
                  example:
                    - est
                  items:
                    type: string
              required:
                - name
                - height
                - width
                - fields
      security: []
  '/api/certificate_template/{id}':
    get:
      summary: 'Retrieves a single certificate template.'
      operationId: retrievesASingleCertificateTemplate
      description: "Returns a single certificate template based on the id provided.\n(See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: Completion-Certificate
                  organization_id: 1
                  bg_url: 'http://aom.com/images/default-certificate.png'
                  height: 680
                  width: 1075
                  fields:
                    -
                      key: course_name
                      value: 'Course Name'
                      font_size: 20
                      font_family: Arial
                      font_color: '#222'
                      top: 432
                      left: 469
                      align_center: false
                      width: 200
                      height: 40
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: Completion-Certificate
                  organization_id:
                    type: integer
                    example: 1
                  bg_url:
                    type: string
                    example: 'http://aom.com/images/default-certificate.png'
                  height:
                    type: integer
                    example: 680
                  width:
                    type: integer
                    example: 1075
                  fields:
                    type: array
                    example:
                      -
                        key: course_name
                        value: 'Course Name'
                        font_size: 20
                        font_family: Arial
                        font_color: '#222'
                        top: 432
                        left: 469
                        align_center: false
                        width: 200
                        height: 40
                    items:
                      type: object
                      properties:
                        key:
                          type: string
                          example: course_name
                        value:
                          type: string
                          example: 'Course Name'
                        font_size:
                          type: integer
                          example: 20
                        font_family:
                          type: string
                          example: Arial
                        font_color:
                          type: string
                          example: '#222'
                        top:
                          type: integer
                          example: 432
                        left:
                          type: integer
                          example: 469
                        align_center:
                          type: boolean
                          example: false
                        width:
                          type: integer
                          example: 200
                        height:
                          type: integer
                          example: 40
      tags:
        - 'Certificate Templates'
      security: []
    put:
      summary: 'Update Certificate Template'
      operationId: updateCertificateTemplate
      description: 'Updates the details of a specified certificate template.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Certificate Template updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Certificate Template updated successfully'
      tags:
        - 'Certificate Templates'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'The name of the certificate template.'
                  example: Completion-Certificate
                organization_id:
                  type: integer
                  description: 'optional The ID of the organization associated with the certificate template.'
                  example: 19
                bg_url:
                  type: string
                  description: 'optional The URL of the background image for the certificate template.'
                  example: 'http://aom.com/images/default-certificate.png'
                height:
                  type: integer
                  description: 'The height of the certificate template.'
                  example: 680
                width:
                  type: integer
                  description: 'The width of the certificate template.'
                  example: 1075
                fields:
                  type: array
                  description: 'The array of fields to be included in the certificate. Each field contains its properties like key, font size, font family, etc.'
                  example:
                    - praesentium
                  items:
                    type: string
              required:
                - name
                - height
                - width
                - fields
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the certificate template.'
        example: facilis
        required: true
        schema:
          type: string
  '/api/certificate_template/preview/{id}':
    get:
      summary: 'Preview Certificate Template'
      operationId: previewCertificateTemplate
      description: "Allows users to preview a certificate template by downloading it with demo data.\nSimulates 100% completion and marks the text module as completed."
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: 'PDF file as a download'
      tags:
        - 'Certificate Templates'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the certificate template.'
        example: '2'
        required: true
        schema:
          type: string
  /api/certificate_template/delete:
    post:
      summary: 'Deletes a certificate template or multiple templates.'
      operationId: deletesACertificateTemplateOrMultipleTemplates
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n    \"message\": \"1 template(s) deleted. 2 template(s) not deleted as it is used in course. Please remove the template(s) from the course and try again.\",\n    \"deletedTemplates\": [1],\n    \"notDeletedTemplates\": [2,3],\n    \"coursesWithTemplates\": { \"2\": [{\"id\": 2, \"name\": \"Course 2\"}, {\"id\": 3, \"name\": \"Course 3\"}]\n}"
      tags:
        - 'Certificate Templates'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: string
                  description: 'The IDs of the certificate templates to be deleted.'
                  example: '[1,2,3]'
              required:
                - delete_ids
      security: []
  /api/certificate/clone:
    post:
      summary: 'Clone Certificate Template'
      operationId: cloneCertificateTemplate
      description: 'Clones the selected certificate template to create a new one with same settings. The new template name is set as "<Original Template Name>_copy"'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Certificate Template Cloned Successfully'
                properties:
                  message:
                    type: string
                    example: 'Certificate Template Cloned Successfully'
      tags:
        - 'Certificate Templates'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                templateId:
                  type: required
                  description: 'integer The ID of the certificate template you want to clone.'
                  example: porro
      security: []
  /api/course/ratings/details:
    get:
      summary: 'Load Course Rating Details'
      operationId: loadCourseRatingDetails
      description: 'Retrieves the course ratings with details. The response includes course name, course ID, rating, reviews, user ID, user display name, user avatar, and submission date.'
      parameters:
        -
          in: query
          name: page_size
          description: 'Number of records to return per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'Number of records to return per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number.'
            example: '1'
        -
          in: query
          name: courseIds
          description: 'An array of course IDs to filter the ratings by.'
          example: '[1,2,3]'
          required: true
          schema:
            type: string
            description: 'An array of course IDs to filter the ratings by.'
            example: '[1,2,3]'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  ratings:
                    -
                      id: 1
                      courseName: 'Course 1'
                      courseId: 1
                      rating: 4.5
                      userId: 1
                      reviews: 'This is a sample review'
                      userDisplayName: 'John Doe'
                      avatar: '<svg...>'
                      submissionDate: 'Feb 2020'
                  total: 20
                  recordsFiltered: 10
                properties:
                  ratings:
                    type: array
                    example:
                      -
                        id: 1
                        courseName: 'Course 1'
                        courseId: 1
                        rating: 4.5
                        userId: 1
                        reviews: 'This is a sample review'
                        userDisplayName: 'John Doe'
                        avatar: '<svg...>'
                        submissionDate: 'Feb 2020'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        courseName:
                          type: string
                          example: 'Course 1'
                        courseId:
                          type: integer
                          example: 1
                        rating:
                          type: number
                          example: 4.5
                        userId:
                          type: integer
                          example: 1
                        reviews:
                          type: string
                          example: 'This is a sample review'
                        userDisplayName:
                          type: string
                          example: 'John Doe'
                        avatar:
                          type: string
                          example: '<svg...>'
                        submissionDate:
                          type: string
                          example: 'Feb 2020'
                  total:
                    type: integer
                    example: 20
                  recordsFiltered:
                    type: integer
                    example: 10
      tags:
        - Courses
      security: []
  /api/courses/curriculum:
    get:
      summary: 'Retrieve course curriculum details'
      operationId: retrieveCourseCurriculumDetails
      description: 'Retrieves the course curriculum details given a set of course IDs. The response includes course name, modules, and sections.'
      parameters:
        -
          in: query
          name: courseIds
          description: 'An array of course IDs to retrieve their curriculum details. example: [1,2,3]'
          example: placeat
          required: true
          schema:
            type: string
            description: 'An array of course IDs to retrieve their curriculum details. example: [1,2,3]'
            example: placeat
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    name: 'Course 1'
                    modules:
                      -
                        module_id: 1
                        name: 'Test Module 1'
                        type: text
                        display_type: Text
                        icon: el-icon-tickets
                      -
                        section_name: 'Section 1'
                        modules:
                          -
                            module_id: 2
                            name: 'Test Module 2'
                            type: video
                            display_type: Video
                            icon: el-icon-video-camera
      tags:
        - Courses
      security: []
  /api/courses/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the courses in a tabular list format with pagination mode.\nYou can apply filter using search_param via courseName, courseCategoryIds and status."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"courseCategoryIds": [1,2], "courseName": "", "status": "DRAFT"}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"courseCategoryIds": [1,2], "courseName": "", "status": "DRAFT"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      name: 'Test Course'
                      slug: test-course
                      status: DRAFT
                      display_status: Draft
                      categories: 'Category 1, Category 2'
                      author: 'John Doe'
                      created_at: 'Aug 26, 2020 12:00 AM'
                      certificate_template_id: 1
                      accredible_group_id: []
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Test Course'
                        slug: test-course
                        status: DRAFT
                        display_status: Draft
                        categories: 'Category 1, Category 2'
                        author: 'John Doe'
                        created_at: 'Aug 26, 2020 12:00 AM'
                        certificate_template_id: 1
                        accredible_group_id: []
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Test Course'
                        slug:
                          type: string
                          example: test-course
                        status:
                          type: string
                          example: DRAFT
                        display_status:
                          type: string
                          example: Draft
                        categories:
                          type: string
                          example: 'Category 1, Category 2'
                        author:
                          type: string
                          example: 'John Doe'
                        created_at:
                          type: string
                          example: 'Aug 26, 2020 12:00 AM'
                        certificate_template_id:
                          type: integer
                          example: 1
                        accredible_group_id:
                          type: array
                          example: []
      tags:
        - Courses
      security: []
  /api/courses/dropdownlist:
    get:
      summary: 'Dropdown List'
      operationId: dropdownList
      description: "Retrieves all the courses in a dropdown format in paginated mode.\nYou can apply filter using portal_id via query param."
      parameters:
        -
          in: query
          name: portalId
          description: 'The portal ID used for additional filtering.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'The portal ID used for additional filtering.'
            example: 5
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'Course 1'
                  -
                    id: 2
                    name: 'Course 2'
      tags:
        - Courses
      security: []
  /api/course/enrolled-students:
    get:
      summary: 'Enrolled Learners'
      operationId: enrolledLearners
      description: 'Retrieves all enrolled students for a course.'
      parameters:
        -
          in: query
          name: course_id
          description: 'The ID of course.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of course.'
            example: '1'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: '5'
          required: true
          schema:
            type: string
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: '5'
        -
          in: query
          name: page_size
          description: 'Number of the results you want in each page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'Number of the results you want in each page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current Page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current Page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'Returns details in some order.'
          example: registered_on
          required: false
          schema:
            type: string
            description: 'Returns details in some order.'
            example: registered_on
        -
          in: query
          name: search_param
          description: 'Search parameters related to course.'
          example: '{"status":["Not Started","In Progress"],"nameOrEmail":"John Doe"}'
          required: false
          schema:
            type: string
            description: 'Search parameters related to course.'
            example: '{"status":["Not Started","In Progress"],"nameOrEmail":"John Doe"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  courseName: 'course 1'
                  featuredImage: 'http://localhost:8000/storage/courses/1/featured_image.jpg'
                  recordsTotal: 12
                  totalNotStarted: 3
                  totalInProgress: 4
                  totalCompleted: 5
                  recordsFiltered: 12
                  records:
                    -
                      id: 1
                      user_id: 2
                      first_name: John
                      last_name: Doe
                      email: john@example.com
                      avatar: 'http://localhost:8000/storage/users/2/avatar.jpg'
                      status: 'Not Started'
                      display_status: 'Not Started'
                      percentComplete: 0
                      access_status: Allowed
                      registered_on: 'Aug 09, 2020'
                      started_on: ''
                      completed_on: ''
                      expire_on: Never
                      last_accessed_on: Never
                      certificate_count: 0
                      user_type: Learner
                      raw_user_type: learner
                properties:
                  courseName:
                    type: string
                    example: 'course 1'
                  featuredImage:
                    type: string
                    example: 'http://localhost:8000/storage/courses/1/featured_image.jpg'
                  recordsTotal:
                    type: integer
                    example: 12
                  totalNotStarted:
                    type: integer
                    example: 3
                  totalInProgress:
                    type: integer
                    example: 4
                  totalCompleted:
                    type: integer
                    example: 5
                  recordsFiltered:
                    type: integer
                    example: 12
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        user_id: 2
                        first_name: John
                        last_name: Doe
                        email: john@example.com
                        avatar: 'http://localhost:8000/storage/users/2/avatar.jpg'
                        status: 'Not Started'
                        display_status: 'Not Started'
                        percentComplete: 0
                        access_status: Allowed
                        registered_on: 'Aug 09, 2020'
                        started_on: ''
                        completed_on: ''
                        expire_on: Never
                        last_accessed_on: Never
                        certificate_count: 0
                        user_type: Learner
                        raw_user_type: learner
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        user_id:
                          type: integer
                          example: 2
                        first_name:
                          type: string
                          example: John
                        last_name:
                          type: string
                          example: Doe
                        email:
                          type: string
                          example: john@example.com
                        avatar:
                          type: string
                          example: 'http://localhost:8000/storage/users/2/avatar.jpg'
                        status:
                          type: string
                          example: 'Not Started'
                        display_status:
                          type: string
                          example: 'Not Started'
                        percentComplete:
                          type: integer
                          example: 0
                        access_status:
                          type: string
                          example: Allowed
                        registered_on:
                          type: string
                          example: 'Aug 09, 2020'
                        started_on:
                          type: string
                          example: ''
                        completed_on:
                          type: string
                          example: ''
                        expire_on:
                          type: string
                          example: Never
                        last_accessed_on:
                          type: string
                          example: Never
                        certificate_count:
                          type: integer
                          example: 0
                        user_type:
                          type: string
                          example: Learner
                        raw_user_type:
                          type: string
                          example: learner
      tags:
        - Courses
      security: []
  /api/course/webinars:
    get:
      summary: 'Retrieve the list of webinars for a given course'
      operationId: retrieveTheListOfWebinarsForAGivenCourse
      description: "This API retrieves the list of webinars for a given course ID.\nThe response includes the webinar name, start date, end date, duration, location, instructor, and other relevant information."
      parameters:
        -
          in: query
          name: search_param
          description: 'JSON object containing search parameters.'
          example: '{"dates": ["2020-07-01", "2020-07-31"]}'
          required: false
          schema:
            type: string
            description: 'JSON object containing search parameters.'
            example: '{"dates": ["2020-07-01", "2020-07-31"]}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'Webinar 1'
                    startDate: '2020-07-01'
                    endDate: '2020-07-01'
                    duration: '1 hour'
                    location: 'New York'
                    instructor: 'John Doe'
                  -
                    id: 2
                    name: 'Webinar 2'
                    startDate: '2020-07-01'
                    endDate: '2020-07-01'
                    duration: '1 hour'
                    location: 'New York'
                    instructor: 'Jane Doe'
      tags:
        - Courses
      security: []
    parameters:
      -
        in: path
        name: course_id
        description: 'The ID of the course to retrieve webinars for.'
        example: '1'
        required: true
        schema:
          type: string
  /api/course/learning-resources:
    get:
      summary: 'Retrieve the list of learning resources for a given course'
      operationId: retrieveTheListOfLearningResourcesForAGivenCourse
      description: "This API retrieves the list of learning resources for a given course ID.\nThe response includes the learning resource name, type, file name, file type, status, s3_url, mux_url, mux_id, bunny_video_id, bunny_video_url, mime_type, created at."
      parameters:
        -
          in: query
          name: search_param
          description: 'JSON object containing search parameters.'
          example: '{}'
          required: false
          schema:
            type: string
            description: 'JSON object containing search parameters.'
            example: '{}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'Learning Resource 1'
                    type: video
                    file_name: LR1.mp4
                    file_type: mp4
                    status: active
                    s3_url: 'https://example.com/LR1.mp4'
                    mux_url: 'https://example.com/LR1.mux'
                    mux_id: mux-id-1
                    bunny_video_id: bunny-video-id-1
                    bunny_video_url: 'https://example.com/LR1.bunny'
                    mime_type: video/mp4
                    created_at: '2020-07-01 10:00:00'
                  -
                    id: 2
                    name: 'Learning Resource 2'
                    type: document
                    file_name: LR2.pdf
                    file_type: pdf
                    status: active
                    s3_url: 'https://example.com/LR2.pdf'
                    mux_url: 'https://example.com/LR2.mux'
                    mux_id: mux-id-2
                    bunny_video_id: bunny-video-id-2
                    bunny_video_url: 'https://example.com/LR2.bunny'
                    mime_type: application/pdf
                    created_at: '2020-07-01 10:00:00'
      tags:
        - Courses
      security: []
    parameters:
      -
        in: path
        name: course_id
        description: 'The ID of the course to retrieve learning resources for.'
        example: '1'
        required: true
        schema:
          type: string
  /api/course/submissions:
    get:
      summary: 'Retrieves all the submissions for all the courses a user is enrolled in, for a given portal'
      operationId: retrievesAllTheSubmissionsForAllTheCoursesAUserIsEnrolledInForAGivenPortal
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'Number of results per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'Number of results per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The current page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'JSON object specifying the column and direction to sort by.'
          example:
            column: name
            direction: asc
          required: false
          schema:
            type: object
            description: 'JSON object specifying the column and direction to sort by.'
            example:
              column: name
              direction: asc
            properties: {  }
        -
          in: query
          name: search_param
          description: 'JSON object containing search criteria.'
          example:
            name: 'John Doe'
            type: assignment
            status: Submitted
          required: false
          schema:
            type: object
            description: 'JSON object containing search criteria.'
            example:
              name: 'John Doe'
              type: assignment
              status: Submitted
            properties: {  }
        -
          in: query
          name: portalId
          description: 'ID of the portal to filter results.'
          example: 5
          required: true
          schema:
            type: integer
            description: 'ID of the portal to filter results.'
            example: 5
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  courseName: 'course name'
                  featuredImage: 'http://localhost:8000/storage/courses/1/featured_image.jpg'
                  totalPending: 5
                  recordsTotal: 12
                  recordsFiltered: 12
                  records:
                    -
                      status_row_id: 1
                      module_id: 1
                      module_name: 'Assignment 1'
                      module_type: assignment
                      module_status: Submitted
                      first_name: John
                      last_name: Doe
                      email: john.doe@example.com
                      avatar: 'https://example.com/avatar.jpg'
                      submission_id: 1
                      submitted_on: '2020-01-01'
                    -
                      status_row_id: 2
                      module_id: 2
                      module_name: 'Discussion 1'
                      module_type: discussion
                      module_status: Submitted
                      first_name: Jane
                      last_name: Doe
                      email: jane.doe@example.com
                      avatar: 'https://example.com/avatar.jpg'
                      submission_id: 2
                      submitted_on: '2020-01-01'
                properties:
                  courseName:
                    type: string
                    example: 'course name'
                  featuredImage:
                    type: string
                    example: 'http://localhost:8000/storage/courses/1/featured_image.jpg'
                  totalPending:
                    type: integer
                    example: 5
                  recordsTotal:
                    type: integer
                    example: 12
                  recordsFiltered:
                    type: integer
                    example: 12
                  records:
                    type: array
                    example:
                      -
                        status_row_id: 1
                        module_id: 1
                        module_name: 'Assignment 1'
                        module_type: assignment
                        module_status: Submitted
                        first_name: John
                        last_name: Doe
                        email: john.doe@example.com
                        avatar: 'https://example.com/avatar.jpg'
                        submission_id: 1
                        submitted_on: '2020-01-01'
                      -
                        status_row_id: 2
                        module_id: 2
                        module_name: 'Discussion 1'
                        module_type: discussion
                        module_status: Submitted
                        first_name: Jane
                        last_name: Doe
                        email: jane.doe@example.com
                        avatar: 'https://example.com/avatar.jpg'
                        submission_id: 2
                        submitted_on: '2020-01-01'
                    items:
                      type: object
                      properties:
                        status_row_id:
                          type: integer
                          example: 1
                        module_id:
                          type: integer
                          example: 1
                        module_name:
                          type: string
                          example: 'Assignment 1'
                        module_type:
                          type: string
                          example: assignment
                        module_status:
                          type: string
                          example: Submitted
                        first_name:
                          type: string
                          example: John
                        last_name:
                          type: string
                          example: Doe
                        email:
                          type: string
                          example: john.doe@example.com
                        avatar:
                          type: string
                          example: 'https://example.com/avatar.jpg'
                        submission_id:
                          type: integer
                          example: 1
                        submitted_on:
                          type: string
                          example: '2020-01-01'
      tags:
        - Courses
      security: []
  /api/course/all-submissions:
    get:
      summary: 'Retrieves all the submissions for all the courses a user is enrolled in, for a given portal'
      operationId: retrievesAllTheSubmissionsForAllTheCoursesAUserIsEnrolledInForAGivenPortal
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'Number of results per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'Number of results per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The current page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'JSON object specifying the column and direction to sort by.'
          example:
            column: name
            direction: asc
          required: false
          schema:
            type: object
            description: 'JSON object specifying the column and direction to sort by.'
            example:
              column: name
              direction: asc
            properties: {  }
        -
          in: query
          name: search_param
          description: 'JSON object containing search criteria.'
          example:
            name: 'Course Name'
          required: false
          schema:
            type: object
            description: 'JSON object containing search criteria.'
            example:
              name: 'Course Name'
            properties: {  }
        -
          in: query
          name: portalId
          description: 'ID of the portal to filter results.'
          example: 5
          required: true
          schema:
            type: integer
            description: 'ID of the portal to filter results.'
            example: 5
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  totalPending: 5
                  records:
                    -
                      course_name: 'Course 1'
                      status_row_id: 1
                      module_id: 1
                      module_name: 'Assignment 1'
                      module_type: assignment
                      module_status: Submitted
                      first_name: John
                      last_name: Doe
                      email: john.doe@example.com
                      avatar: 'https://example.com/avatar.jpg'
                      submission_id: 1
                      submitted_on: '2020-01-01'
                    -
                      course_name: 'Course 2'
                      status_row_id: 2
                      module_id: 2
                      module_name: 'Discussion 1'
                      module_type: discussion
                      module_status: Submitted
                      first_name: Jane
                      last_name: Doe
                      email: jane.doe@example.com
                      avatar: 'https://example.com/avatar.jpg'
                      submission_id: 2
                      submitted_on: '2020-01-01'
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  totalPending:
                    type: integer
                    example: 5
                  records:
                    type: array
                    example:
                      -
                        course_name: 'Course 1'
                        status_row_id: 1
                        module_id: 1
                        module_name: 'Assignment 1'
                        module_type: assignment
                        module_status: Submitted
                        first_name: John
                        last_name: Doe
                        email: john.doe@example.com
                        avatar: 'https://example.com/avatar.jpg'
                        submission_id: 1
                        submitted_on: '2020-01-01'
                      -
                        course_name: 'Course 2'
                        status_row_id: 2
                        module_id: 2
                        module_name: 'Discussion 1'
                        module_type: discussion
                        module_status: Submitted
                        first_name: Jane
                        last_name: Doe
                        email: jane.doe@example.com
                        avatar: 'https://example.com/avatar.jpg'
                        submission_id: 2
                        submitted_on: '2020-01-01'
                    items:
                      type: object
                      properties:
                        course_name:
                          type: string
                          example: 'Course 1'
                        status_row_id:
                          type: integer
                          example: 1
                        module_id:
                          type: integer
                          example: 1
                        module_name:
                          type: string
                          example: 'Assignment 1'
                        module_type:
                          type: string
                          example: assignment
                        module_status:
                          type: string
                          example: Submitted
                        first_name:
                          type: string
                          example: John
                        last_name:
                          type: string
                          example: Doe
                        email:
                          type: string
                          example: john.doe@example.com
                        avatar:
                          type: string
                          example: 'https://example.com/avatar.jpg'
                        submission_id:
                          type: integer
                          example: 1
                        submitted_on:
                          type: string
                          example: '2020-01-01'
      tags:
        - Courses
      security: []
  /api/course/reports/overview:
    get:
      summary: 'API to fetch LMS Overview Report'
      operationId: aPIToFetchLMSOverviewReport
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  labels: []
                  totalNotStarted: []
                  totalInProgress: []
                  totalCompleted: []
                  percentageCompleted: []
                  sumNotStarted: 0
                  sumInProgress: 0
                  sumCompleted: 0
                  sumPercentageCompleted: 0
                properties:
                  labels:
                    type: array
                    example: []
                  totalNotStarted:
                    type: array
                    example: []
                  totalInProgress:
                    type: array
                    example: []
                  totalCompleted:
                    type: array
                    example: []
                  percentageCompleted:
                    type: array
                    example: []
                  sumNotStarted:
                    type: integer
                    example: 0
                  sumInProgress:
                    type: integer
                    example: 0
                  sumCompleted:
                    type: integer
                    example: 0
                  sumPercentageCompleted:
                    type: integer
                    example: 0
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                searchPortalIds:
                  type: array
                  description: 'Portal Ids'
                  example:
                    - est
                  items:
                    type: string
              required:
                - searchPortalIds
      security: []
  /api/course/reports/course-detailed:
    get:
      summary: 'API to get Course Detail Report'
      operationId: aPIToGetCourseDetailReport
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 0
                  totalNotStarted: 0
                  totalInProgress: 0
                  totalCompleted: 0
                  recordsFiltered: 0
                  records:
                    -
                      user_id: 0
                      course_id: 0
                      first_name: ''
                      last_name: ''
                      email: ''
                      course_name: ''
                      portal_name: ''
                      status: ''
                      display_status: ''
                      percent_complete: 0
                      access_status: ''
                      registered_on: ''
                      started_on: ''
                      completed_on: ''
                      expire_on: ''
                      last_accessed_on: ''
                      percent_achieved: 0
                      total_time_spent: ''
                      certifcate_issued: ''
                      certifcate_count: ''
                      certifcate_issued_date: ''
                      certificate_expire: ''
                properties:
                  recordsTotal:
                    type: integer
                    example: 0
                  totalNotStarted:
                    type: integer
                    example: 0
                  totalInProgress:
                    type: integer
                    example: 0
                  totalCompleted:
                    type: integer
                    example: 0
                  recordsFiltered:
                    type: integer
                    example: 0
                  records:
                    type: array
                    example:
                      -
                        user_id: 0
                        course_id: 0
                        first_name: ''
                        last_name: ''
                        email: ''
                        course_name: ''
                        portal_name: ''
                        status: ''
                        display_status: ''
                        percent_complete: 0
                        access_status: ''
                        registered_on: ''
                        started_on: ''
                        completed_on: ''
                        expire_on: ''
                        last_accessed_on: ''
                        percent_achieved: 0
                        total_time_spent: ''
                        certifcate_issued: ''
                        certifcate_count: ''
                        certifcate_issued_date: ''
                        certificate_expire: ''
                    items:
                      type: object
                      properties:
                        user_id:
                          type: integer
                          example: 0
                        course_id:
                          type: integer
                          example: 0
                        first_name:
                          type: string
                          example: ''
                        last_name:
                          type: string
                          example: ''
                        email:
                          type: string
                          example: ''
                        course_name:
                          type: string
                          example: ''
                        portal_name:
                          type: string
                          example: ''
                        status:
                          type: string
                          example: ''
                        display_status:
                          type: string
                          example: ''
                        percent_complete:
                          type: integer
                          example: 0
                        access_status:
                          type: string
                          example: ''
                        registered_on:
                          type: string
                          example: ''
                        started_on:
                          type: string
                          example: ''
                        completed_on:
                          type: string
                          example: ''
                        expire_on:
                          type: string
                          example: ''
                        last_accessed_on:
                          type: string
                          example: ''
                        percent_achieved:
                          type: integer
                          example: 0
                        total_time_spent:
                          type: string
                          example: ''
                        certifcate_issued:
                          type: string
                          example: ''
                        certifcate_count:
                          type: string
                          example: ''
                        certifcate_issued_date:
                          type: string
                          example: ''
                        certificate_expire:
                          type: string
                          example: ''
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                course_ids:
                  type: array
                  description: 'The course ids to filter the report'
                  example:
                    - qui
                  items:
                    type: string
                page_size:
                  type: integer
                  description: 'The number of records per page'
                  example: 12
                page_number:
                  type: integer
                  description: 'The page number to request'
                  example: 12
                order_by:
                  type: object
                  description: 'The column name and direction to order the report by'
                  example: []
                  properties: {  }
                search_param:
                  type: object
                  description: 'The search parameters to filter the report by'
                  example: []
                  properties: {  }
                userCategoryId:
                  type: integer
                  description: 'The user category id to filter the report by'
                  example: 18
                registered_between:
                  type: array
                  description: 'The date range to filter the report by'
                  example:
                    - mollitia
                  items:
                    type: string
                searchPortalIds:
                  type: array
                  description: 'The portal ids to filter the report by'
                  example:
                    - sapiente
                  items:
                    type: string
              required:
                - course_ids
                - page_size
                - page_number
                - order_by
                - search_param
                - userCategoryId
                - registered_between
                - searchPortalIds
      security: []
  /api/course/reports/course-detailed-custom-headers:
    get:
      summary: 'Get the list of custom user metas that needs to be printed on the Course Insight Export report'
      operationId: getTheListOfCustomUserMetasThatNeedsToBePrintedOnTheCourseInsightExportReport
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "[\n    \"user_meta_key_1\" => \"Label 1\",\n    \"user_meta_key_2\" => \"Label 2\"\n]"
      tags:
        - Courses
      security: []
  '/api/course/{id}':
    get:
      summary: 'Retrieve Course Details'
      operationId: retrieveCourseDetails
      description: "Fetches detailed information for a specific course, including metadata, modules, categories,\nlearning paths, and associated resources."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'Course Name'
                  slug: course-name
                  featuredImageUrl: 'https://example.com/image.jpg'
                  instructions: 'Course instructions'
                  credits: 3
                  estimatedCompletion: 10
                  estimationCompletedUnit: hours
                  minPassingPercentage: 70
                  gradingRule: average
                  durationRule: fixed
                  durationSpecificDate: '2025-06-01'
                  durationDays: 30
                  selectedBadgeId: 1
                  isBadgeSelected: badge
                  points: 100
                  status: published
                  certificateTemplates:
                    - 1
                    - 2
                  associatedProduct: []
                  shopifyProducts:
                    - 101
                    - 102
                  completionRedirectionUrl: 'https://example.com/completion'
                  certificateExpiresAfter: 365
                  certificateExpiresAfterGracePeriod: 30
                  accredibleGroupId:
                    - 5
                    - 6
                  enableCourseRating: true
                  completionCriteria: all_modules
                  hasAssociatedProduct: false
                  modules:
                    -
                      module_id: 1
                      display_order: 1
                      name: 'Module Name'
                      type: text
                      icon: '<i class="el-icon-tickets"></i>'
                      is_locked: false
                      drip_rules: immediately
                      drip_fixed_date: null
                      drip_interval: null
                      drip_interval_unit: day
                      drip_calculation_reference: registration_date
                      selectedModuleBadgeId: 1
                      modulePoints: 10
                      isModuleBadgeSelected: badge
                      minSpentHour: 0
                      minSpentMinutes: 0
                  categories:
                    - 1
                    - 2
                  gradeModules:
                    - 1
                    - 2
                  selectedModules:
                    - 1
                    - -999
                  learningPaths:
                    -
                      learning_path_id: 1
                      learning_path_name: 'Learning Path Name'
                  learningResources: []
                  webinarList: []
                  selectedWebinars:
                    - -999
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'Course Name'
                  slug:
                    type: string
                    example: course-name
                  featuredImageUrl:
                    type: string
                    example: 'https://example.com/image.jpg'
                  instructions:
                    type: string
                    example: 'Course instructions'
                  credits:
                    type: integer
                    example: 3
                  estimatedCompletion:
                    type: integer
                    example: 10
                  estimationCompletedUnit:
                    type: string
                    example: hours
                  minPassingPercentage:
                    type: integer
                    example: 70
                  gradingRule:
                    type: string
                    example: average
                  durationRule:
                    type: string
                    example: fixed
                  durationSpecificDate:
                    type: string
                    example: '2025-06-01'
                  durationDays:
                    type: integer
                    example: 30
                  selectedBadgeId:
                    type: integer
                    example: 1
                  isBadgeSelected:
                    type: string
                    example: badge
                  points:
                    type: integer
                    example: 100
                  status:
                    type: string
                    example: published
                  certificateTemplates:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  associatedProduct:
                    type: array
                    example: []
                  shopifyProducts:
                    type: array
                    example:
                      - 101
                      - 102
                    items:
                      type: integer
                  completionRedirectionUrl:
                    type: string
                    example: 'https://example.com/completion'
                  certificateExpiresAfter:
                    type: integer
                    example: 365
                  certificateExpiresAfterGracePeriod:
                    type: integer
                    example: 30
                  accredibleGroupId:
                    type: array
                    example:
                      - 5
                      - 6
                    items:
                      type: integer
                  enableCourseRating:
                    type: boolean
                    example: true
                  completionCriteria:
                    type: string
                    example: all_modules
                  hasAssociatedProduct:
                    type: boolean
                    example: false
                  modules:
                    type: array
                    example:
                      -
                        module_id: 1
                        display_order: 1
                        name: 'Module Name'
                        type: text
                        icon: '<i class="el-icon-tickets"></i>'
                        is_locked: false
                        drip_rules: immediately
                        drip_fixed_date: null
                        drip_interval: null
                        drip_interval_unit: day
                        drip_calculation_reference: registration_date
                        selectedModuleBadgeId: 1
                        modulePoints: 10
                        isModuleBadgeSelected: badge
                        minSpentHour: 0
                        minSpentMinutes: 0
                    items:
                      type: object
                      properties:
                        module_id:
                          type: integer
                          example: 1
                        display_order:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Module Name'
                        type:
                          type: string
                          example: text
                        icon:
                          type: string
                          example: '<i class="el-icon-tickets"></i>'
                        is_locked:
                          type: boolean
                          example: false
                        drip_rules:
                          type: string
                          example: immediately
                        drip_fixed_date:
                          type: string
                          example: null
                        drip_interval:
                          type: string
                          example: null
                        drip_interval_unit:
                          type: string
                          example: day
                        drip_calculation_reference:
                          type: string
                          example: registration_date
                        selectedModuleBadgeId:
                          type: integer
                          example: 1
                        modulePoints:
                          type: integer
                          example: 10
                        isModuleBadgeSelected:
                          type: string
                          example: badge
                        minSpentHour:
                          type: integer
                          example: 0
                        minSpentMinutes:
                          type: integer
                          example: 0
                  categories:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  gradeModules:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  selectedModules:
                    type: array
                    example:
                      - 1
                      - -999
                    items:
                      type: integer
                  learningPaths:
                    type: array
                    example:
                      -
                        learning_path_id: 1
                        learning_path_name: 'Learning Path Name'
                    items:
                      type: object
                      properties:
                        learning_path_id:
                          type: integer
                          example: 1
                        learning_path_name:
                          type: string
                          example: 'Learning Path Name'
                  learningResources:
                    type: array
                    example: []
                  webinarList:
                    type: array
                    example: []
                  selectedWebinars:
                    type: array
                    example:
                      - -999
                    items:
                      type: integer
      tags:
        - Courses
      security: []
    put:
      summary: 'Update Course Details'
      operationId: updateCourseDetails
      description: "Use this endpoint to update a course's settings, including curriculum, certification, grading, duration, and other metadata."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Course updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Course updated successfully'
      tags:
        - Courses
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'The course title.'
                  example: '"Professional Development and Training"'
                status:
                  type: string
                  description: 'The course status (e.g., draft, published).'
                  example: '"published"'
                featuredImageUrl:
                  type: string
                  description: "URL of the course's featured image."
                  example: '"https://example.com/image.jpg"'
                instructions:
                  type: string
                  description: 'Additional instructions for the course.'
                  example: '"Complete all modules."'
                credits:
                  type: integer
                  description: 'Number of credits assigned to the course.'
                  example: 3
                estimatedCompletion:
                  type: integer
                  description: 'Estimated time to complete the course.'
                  example: 10
                estimationCompletedUnit:
                  type: string
                  description: 'Unit for estimated completion (e.g., hours, days).'
                  example: '"hours"'
                minPassingPercentage:
                  type: numeric
                  description: 'Minimum passing score percentage.'
                  example: '70'
                gradingRule:
                  type: array
                  description: 'Rules for course grading.'
                  example:
                    -
                      type: average
                      weight: 50
                  items:
                    type: string
                durationRule:
                  type: string
                  description: 'Type of duration rule.'
                  example: '"fixed"'
                durationSpecificDate:
                  type: date
                  description: 'The specific date when course access ends (if applicable).'
                  example: '"2025-06-01"'
                durationDays:
                  type: integer
                  description: 'Number of days the course is accessible.'
                  example: 30
                points:
                  type: integer
                  description: 'Points rewarded upon completion.'
                  example: 100
                certificateTemplates:
                  type: integer
                  description: 'ID of the certificate template.'
                  example: 2
                certificateExpiresAfter:
                  type: integer
                  description: 'Certificate validity period in days.'
                  example: 365
                certificateExpiresAfterGracePeriod:
                  type: integer
                  description: 'Grace period after expiry in days.'
                  example: 30
                completionRedirectionUrl:
                  type: string
                  description: 'URL to redirect upon course completion.'
                  example: '"https://example.com/congrats"'
                enableCourseRating:
                  type: boolean
                  description: 'Whether course rating is enabled.'
                  example: true
                completionCriteria:
                  type: string
                  description: 'Criteria for course completion.'
                  example: '"all_modules"'
                selectedModules:
                  type: array
                  description: 'Selected module IDs.'
                  example:
                    - 1
                    - 3
                    - 5
                  items:
                    type: string
                selectedWebinars:
                  type: array
                  description: 'Selected webinar IDs.'
                  example:
                    - 10
                    - 11
                  items:
                    type: string
                shopifyProducts:
                  type: array
                  description: 'Shopify product IDs linked to the course.'
                  example:
                    - 101
                    - 102
                  items:
                    type: string
                learningResources:
                  type: array
                  description: 'Associated learning resource IDs.'
                  example:
                    - 201
                    - 202
                  items:
                    type: string
                accredibleGroupId:
                  type: integer
                  description: 'Accredible group ID for certification.'
                  example: 55
                isBadgeSelected:
                  type: string
                  description: "Indicates if badge is selected. Should be 'badge' to use selectedBadgeId."
                  example: '"badge"'
                selectedBadgeId:
                  type: integer
                  description: "ID of the badge to be assigned if isBadgeSelected is 'badge'."
                  example: 7
                modules:
                  type: array
                  description: "The list of modules added to the course with section and drip settings.\nEach module object can contain the following:\n- module_id: integer ID of the module. Example: 1\n- name: string Name of the module. Example: \"Introduction Text Module\"\n- type: string Type of the module. Example: \"text\"\n- section_name: string Name of the section the module belongs to. Example: \"Section 1\"\n- is_locked: boolean Whether the module is locked. Example: false\n- modulePoints: integer Points assigned to the module. Example: 10\n- icon: string Icon HTML used for UI. Example: \"<i class=\\\"el-icon-tickets\\\"></i>\"\n- selectedModuleBadgeId: integer Badge ID assigned to the module. Example: 4\n- drip_rules: string Rule for content drip. Example: \"immediately\"\n- drip_interval: integer Interval before the module is unlocked. Example: 2\n- drip_interval_unit: string Unit of the interval (day/week/month). Example: \"day\"\n- drip_fixed_date: date Fixed date to unlock the module (if applicable). Example: \"2025-01-01\"\n- drip_calculation_reference: string Base date for drip logic (e.g., registration_date)."
                  example: registration_date
                  items:
                    type: string
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the course to retrieve.'
        example: '1'
        required: true
        schema:
          type: string
  /api/course:
    post:
      summary: 'Save Course'
      operationId: saveCourse
      description: "Creates or updates a course with associated modules, categories, certificates, webinars, and settings.\nThis endpoint handles both draft and publish modes. It validates different fields based on the mode.\nIn draft mode, only the course name is required. In publish mode, full validation is enforced including\nmodules, certificates, completion criteria, badges, and grading settings.\n\nIt also links categories (creating new ones if needed), associates selected certificate templates,\nhandles Shopify product mappings, and processes webinar integrations."
      parameters: []
      responses: {  }
      tags:
        - Courses
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'The course title.'
                  example: '"Professional Development and Training"'
                status:
                  type: string
                  description: 'The course status (e.g., draft, published).'
                  example: '"published"'
                featuredImageUrl:
                  type: string
                  description: "URL of the course's featured image."
                  example: '"https://example.com/image.jpg"'
                instructions:
                  type: string
                  description: 'Additional instructions for the course.'
                  example: '"Complete all modules."'
                credits:
                  type: integer
                  description: 'Number of credits assigned to the course.'
                  example: 3
                estimatedCompletion:
                  type: integer
                  description: 'Estimated time to complete the course.'
                  example: 10
                estimationCompletedUnit:
                  type: string
                  description: 'Unit for estimated completion (e.g., hours, days).'
                  example: '"hours"'
                minPassingPercentage:
                  type: numeric
                  description: 'Minimum passing score percentage.'
                  example: '70'
                gradingRule:
                  type: array
                  description: 'Rules for course grading.'
                  example:
                    -
                      type: average
                      weight: 50
                  items:
                    type: string
                durationRule:
                  type: string
                  description: 'Type of duration rule.'
                  example: '"fixed"'
                durationSpecificDate:
                  type: date
                  description: 'The specific date when course access ends (if applicable).'
                  example: '"2025-06-01"'
                durationDays:
                  type: integer
                  description: 'Number of days the course is accessible.'
                  example: 30
                points:
                  type: integer
                  description: 'Points rewarded upon completion.'
                  example: 100
                certificateTemplates:
                  type: integer
                  description: 'ID of the certificate template.'
                  example: 2
                certificateExpiresAfter:
                  type: integer
                  description: 'Certificate validity period in days.'
                  example: 365
                certificateExpiresAfterGracePeriod:
                  type: integer
                  description: 'Grace period after expiry in days.'
                  example: 30
                completionRedirectionUrl:
                  type: string
                  description: 'URL to redirect upon course completion.'
                  example: '"https://example.com/congrats"'
                enableCourseRating:
                  type: boolean
                  description: 'Whether course rating is enabled.'
                  example: true
                completionCriteria:
                  type: string
                  description: 'Criteria for course completion.'
                  example: '"all_modules"'
                selectedModules:
                  type: array
                  description: 'Selected module IDs.'
                  example:
                    - 1
                    - 3
                    - 5
                  items:
                    type: string
                selectedWebinars:
                  type: array
                  description: 'Selected webinar IDs.'
                  example:
                    - 10
                    - 11
                  items:
                    type: string
                shopifyProducts:
                  type: array
                  description: 'Shopify product IDs linked to the course.'
                  example:
                    - 101
                    - 102
                  items:
                    type: string
                learningResources:
                  type: array
                  description: 'Associated learning resource IDs.'
                  example:
                    - 201
                    - 202
                  items:
                    type: string
                accredibleGroupId:
                  type: integer
                  description: 'Accredible group ID for certification.'
                  example: 55
                isBadgeSelected:
                  type: string
                  description: "Indicates if badge is selected. Should be 'badge' to use selectedBadgeId."
                  example: '"badge"'
                selectedBadgeId:
                  type: integer
                  description: "ID of the badge to be assigned if isBadgeSelected is 'badge'."
                  example: 7
                modules:
                  type: array
                  description: "The list of modules added to the course with section and drip settings.\nEach module object can contain the following:\n- module_id: integer ID of the module. Example: 1\n- name: string Name of the module. Example: \"Introduction Text Module\"\n- type: string Type of the module. Example: \"text\"\n- section_name: string Name of the section the module belongs to. Example: \"Section 1\"\n- is_locked: boolean Whether the module is locked. Example: false\n- modulePoints: integer Points assigned to the module. Example: 10\n- icon: string Icon HTML used for UI. Example: \"<i class=\\\"el-icon-tickets\\\"></i>\"\n- selectedModuleBadgeId: integer Badge ID assigned to the module. Example: 4\n- drip_rules: string Rule for content drip. Example: \"immediately\"\n- drip_interval: integer Interval before the module is unlocked. Example: 2\n- drip_interval_unit: string Unit of the interval (day/week/month). Example: \"day\"\n- drip_fixed_date: date Fixed date to unlock the module (if applicable). Example: \"2025-01-01\"\n- drip_calculation_reference: string Base date for drip logic (e.g., registration_date)."
                  example:
                    - consequatur
                  items:
                    type: string
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the course to be updated.'
        example: '1'
        required: true
        schema:
          type: string
  /api/course/lookup:
    post:
      summary: 'Course Lookup'
      operationId: courseLookup
      description: "Retrieves the courses matching the search term provided in the request. If the portalId is provided, it will fetch courses\nwhich are attached to the portal. If the type is report, it will fetch all the courses attached to the membership and\nthe courses attached to the learning path attached to the portal as well."
      parameters:
        -
          in: query
          name: search_term
          description: 'The search term to search for courses.'
          example: 'course 1'
          required: true
          schema:
            type: string
            description: 'The search term to search for courses.'
            example: 'course 1'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: '5'
          required: true
          schema:
            type: string
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: '5'
        -
          in: query
          name: type
          description: 'optional The type of the call.'
          example: report
          required: false
          schema:
            type: string
            description: 'optional The type of the call.'
            example: report
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    value: 1
                    label: 'course 1'
                  -
                    value: 2
                    label: 'course 2'
      tags:
        - Courses
      security: []
  /api/course/delete:
    post:
      summary: 'Deletes courses'
      operationId: deletesCourses
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '3 course(s) deleted, 2 course(s) not deleted as it has enrollments. Please remove the students from the course and try again.'
                  deletedCourses:
                    - 1
                    - 2
                  notDeletedCourses:
                    - 3
                    - 4
                  enrolledCourses:
                    -
                      id: 3
                      name: 'Course 3'
                    -
                      id: 4
                      name: 'Course 4'
                  notDeletedProductCourses:
                    - 1
                    - 3
                  productCourses:
                    'Course 1':
                      -
                        id: 1
                        title: 'Product 1'
                    'Course 3':
                      -
                        id: 2
                        title: 'Product 2'
                  notDeletedAutoEnrolledCourses:
                    - 2
                  autoEnrolledCourses:
                    -
                      courseId: 2
                      courseName: 'Course 2'
                  notDeletedLearningPathCourses:
                    - 4
                  learningPathCourses:
                    'Course 4':
                      -
                        id: 1
                        title: 'Learning Path 1'
                  notDeletedPortalCourses:
                    - 1
                  portalCourses:
                    'Course 1':
                      -
                        id: 1
                        name: 'Portal 1'
                properties:
                  message:
                    type: string
                    example: '3 course(s) deleted, 2 course(s) not deleted as it has enrollments. Please remove the students from the course and try again.'
                  deletedCourses:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  notDeletedCourses:
                    type: array
                    example:
                      - 3
                      - 4
                    items:
                      type: integer
                  enrolledCourses:
                    type: array
                    example:
                      -
                        id: 3
                        name: 'Course 3'
                      -
                        id: 4
                        name: 'Course 4'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 3
                        name:
                          type: string
                          example: 'Course 3'
                  notDeletedProductCourses:
                    type: array
                    example:
                      - 1
                      - 3
                    items:
                      type: integer
                  productCourses:
                    type: object
                    properties:
                      'Course 1':
                        type: array
                        example:
                          -
                            id: 1
                            title: 'Product 1'
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 1
                            title:
                              type: string
                              example: 'Product 1'
                      'Course 3':
                        type: array
                        example:
                          -
                            id: 2
                            title: 'Product 2'
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 2
                            title:
                              type: string
                              example: 'Product 2'
                  notDeletedAutoEnrolledCourses:
                    type: array
                    example:
                      - 2
                    items:
                      type: integer
                  autoEnrolledCourses:
                    type: array
                    example:
                      -
                        courseId: 2
                        courseName: 'Course 2'
                    items:
                      type: object
                      properties:
                        courseId:
                          type: integer
                          example: 2
                        courseName:
                          type: string
                          example: 'Course 2'
                  notDeletedLearningPathCourses:
                    type: array
                    example:
                      - 4
                    items:
                      type: integer
                  learningPathCourses:
                    type: object
                    properties:
                      'Course 4':
                        type: array
                        example:
                          -
                            id: 1
                            title: 'Learning Path 1'
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 1
                            title:
                              type: string
                              example: 'Learning Path 1'
                  notDeletedPortalCourses:
                    type: array
                    example:
                      - 1
                    items:
                      type: integer
                  portalCourses:
                    type: object
                    properties:
                      'Course 1':
                        type: array
                        example:
                          -
                            id: 1
                            name: 'Portal 1'
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 1
                            name:
                              type: string
                              example: 'Portal 1'
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: array
                  description: 'The course IDs to delete.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - delete_ids
      security: []
  /api/course/quickEdit:
    post:
      summary: 'Quick Edit'
      operationId: quickEdit
      description: 'Updates the details of specified courses in bulk. The parameters to be updated are provided in the request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Courses updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Courses updated Successfully'
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                course_ids:
                  type: array
                  description: 'IDs of the courses to be updated.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
                author_id:
                  type: integer
                  description: 'ID of the new instructor/author for the specified courses.'
                  example: 1
                categories_id:
                  type: array
                  description: 'IDs of the categories to update the specified courses with.'
                  example:
                    - 3
                    - 4
                  items:
                    type: string
              required:
                - course_ids
      security: []
  /api/courses/drip/lookup:
    get:
      summary: 'Drip Option Lookup'
      operationId: dripOptionLookup
      description: "Retrieves all the options for the drip feature that the platform offers like Immediately, On a Fixed Date, At Fixed Intervals.\nHelps showing options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    options:
                      -
                        db_value: immediately
                        display_value: Immediately
                      -
                        db_value: fixed_date
                        display_value: 'On a Fixed Date'
                      -
                        db_value: specific_interval
                        display_value: 'At Fixed Intervals'
                    intervals:
                      -
                        db_value: day
                        display_value: Day(s)
                      -
                        db_value: week
                        display_value: Week(s)
                      -
                        db_value: month
                        display_value: Month(s)
                    calculation_ref:
                      -
                        db_value: registration_date
                        display_value: 'Enrollment Date'
                      -
                        db_value: started_date
                        display_value: 'Course Start Date'
      tags:
        - Courses
      security: []
  /api/courses/status/lookup:
    get:
      summary: 'Course Status Lookup'
      operationId: courseStatusLookup
      description: "Retrieves all the statuses for a course the platform offers like Not Started, In Progress, Completed.\nHelps showing options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: 'Not Started'
                    display_value: 'Not Started'
                  -
                    db_value: 'In Progress'
                    display_value: 'In Progress'
                  -
                    db_value: Completed
                    display_value: Completed
      tags:
        - Courses
      security: []
  /api/courses/grading-rules/lookup:
    get:
      summary: 'Grading Rules Lookup'
      operationId: gradingRulesLookup
      description: "Retrieves all the grading rules available for course creation.\nHelps showing options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: no_grading
                    display_value: 'No Grading'
                  -
                    db_value: avg_all_modules
                    display_value: 'Average of all Quiz/Assignment/Discussions/Scorm'
                  -
                    db_value: avg_specific_modules
                    display_value: 'Average of specific Quiz/Assignment/Discussions/Scorm'
      tags:
        - Courses
      security: []
  /api/courses/duration-rules/lookup:
    get:
      summary: 'Duration Rules Lookup'
      operationId: durationRulesLookup
      description: "Retrieves all the duration rules for the courses.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: unlimited
                    display_value: Unlimited
                  -
                    db_value: on_specific_date
                    display_value: 'Till Specific Date'
                  -
                    db_value: x_days_after_start
                    display_value: 'Till X day(s) after a student starts the course'
                  -
                    db_value: x_days_after_enrollment
                    display_value: 'Till X day(s) after a student registers in the course'
      tags:
        - Courses
      security: []
  /api/course-activities:
    get:
      summary: 'Retrieve Course Activities'
      operationId: retrieveCourseActivities
      description: 'Retrieves paginated activities for a specified course based on various parameters.'
      parameters:
        -
          in: query
          name: course_id
          description: 'The ID of the course.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of the course.'
            example: '1'
        -
          in: query
          name: page_size
          description: 'The number of activities you want in each page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of activities you want in each page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'JSON object to order the activities.'
          example: '{"colName":"created_at", "direction":"asc"}'
          required: false
          schema:
            type: string
            description: 'JSON object to order the activities.'
            example: '{"colName":"created_at", "direction":"asc"}'
        -
          in: query
          name: search_param
          description: 'JSON object for searching activities by specific criteria.'
          example: '{"nameOrEmail":"John Doe"}'
          required: false
          schema:
            type: string
            description: 'JSON object for searching activities by specific criteria.'
            example: '{"nameOrEmail":"John Doe"}'
        -
          in: query
          name: context
          description: 'Context in which activities are retrieved.'
          example: '"overview"'
          required: false
          schema:
            type: string
            description: 'Context in which activities are retrieved.'
            example: '"overview"'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter activities by portal and sub-portals. Use -1 to skip portal filtering.'
          example: '5'
          required: false
          schema:
            type: string
            description: 'The portal ID to filter activities by portal and sub-portals. Use -1 to skip portal filtering.'
            example: '5'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  courseName: 'course 1'
                  featuredImage: null
                  recordsTotal: 40
                  recordsFiltered: 10
                  records:
                    -
                      id: 10
                      verb: ACCESSED
                      created_at: 'Aug 03, 2020 10:07 AM'
                      message: 'Demo Student has accessed course 1'
                      student: 'Demo Student'
                    -
                      id: 9
                      verb: 'ACHIEVED CERTIFICATE'
                      created_at: 'Aug 03, 2020 10:02 AM'
                      message: 'Demo Student has achieved certificate for course 1'
                      student: 'Demo Student'
                    -
                      id: 8
                      verb: COMPLETED
                      created_at: 'Aug 03, 2020 10:02 AM'
                      message: 'course 1 was completed'
                      student: 'Demo Student'
                    -
                      id: 7
                      verb: COMPLETED
                      created_at: 'Aug 03, 2020 10:02 AM'
                      message: 'course 1 was completed'
                      student: 'Demo Student'
                    -
                      id: 6
                      verb: 'ACHIEVED CERTIFICATE'
                      created_at: 'Aug 03, 2020 10:02 AM'
                      message: 'Demo Student has achieved certificate for course 1'
                      student: 'Demo Student'
                    -
                      id: 5
                      verb: COMPLETED
                      created_at: 'Aug 03, 2020 10:02 AM'
                      message: 'course 1 was completed'
                      student: 'Demo Student'
                    -
                      id: 4
                      verb: COMPLETED
                      created_at: 'Aug 03, 2020 10:02 AM'
                      message: 'course 1 was completed'
                      student: 'Demo Student'
                    -
                      id: 3
                      verb: STARTED
                      created_at: 'Aug 03, 2020 10:02 AM'
                      message: 'Demo Student has started test'
                      student: 'Demo Student'
                    -
                      id: 2
                      verb: STARTED
                      created_at: 'Aug 03, 2020 10:01 AM'
                      message: 'Demo Student has started course 1'
                      student: 'Demo Student'
                    -
                      id: 1
                      verb: ENROLLED
                      created_at: 'Aug 03, 2020 10:00 AM'
                      message: 'Demo Student is enrolled to course 1'
                      student: 'Demo Student'
                properties:
                  courseName:
                    type: string
                    example: 'course 1'
                  featuredImage:
                    type: string
                    example: null
                  recordsTotal:
                    type: integer
                    example: 40
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 10
                        verb: ACCESSED
                        created_at: 'Aug 03, 2020 10:07 AM'
                        message: 'Demo Student has accessed course 1'
                        student: 'Demo Student'
                      -
                        id: 9
                        verb: 'ACHIEVED CERTIFICATE'
                        created_at: 'Aug 03, 2020 10:02 AM'
                        message: 'Demo Student has achieved certificate for course 1'
                        student: 'Demo Student'
                      -
                        id: 8
                        verb: COMPLETED
                        created_at: 'Aug 03, 2020 10:02 AM'
                        message: 'course 1 was completed'
                        student: 'Demo Student'
                      -
                        id: 7
                        verb: COMPLETED
                        created_at: 'Aug 03, 2020 10:02 AM'
                        message: 'course 1 was completed'
                        student: 'Demo Student'
                      -
                        id: 6
                        verb: 'ACHIEVED CERTIFICATE'
                        created_at: 'Aug 03, 2020 10:02 AM'
                        message: 'Demo Student has achieved certificate for course 1'
                        student: 'Demo Student'
                      -
                        id: 5
                        verb: COMPLETED
                        created_at: 'Aug 03, 2020 10:02 AM'
                        message: 'course 1 was completed'
                        student: 'Demo Student'
                      -
                        id: 4
                        verb: COMPLETED
                        created_at: 'Aug 03, 2020 10:02 AM'
                        message: 'course 1 was completed'
                        student: 'Demo Student'
                      -
                        id: 3
                        verb: STARTED
                        created_at: 'Aug 03, 2020 10:02 AM'
                        message: 'Demo Student has started test'
                        student: 'Demo Student'
                      -
                        id: 2
                        verb: STARTED
                        created_at: 'Aug 03, 2020 10:01 AM'
                        message: 'Demo Student has started course 1'
                        student: 'Demo Student'
                      -
                        id: 1
                        verb: ENROLLED
                        created_at: 'Aug 03, 2020 10:00 AM'
                        message: 'Demo Student is enrolled to course 1'
                        student: 'Demo Student'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 10
                        verb:
                          type: string
                          example: ACCESSED
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 10:07 AM'
                        message:
                          type: string
                          example: 'Demo Student has accessed course 1'
                        student:
                          type: string
                          example: 'Demo Student'
      tags:
        - Courses
      security: []
  '/api/course-progress/edit/{id}':
    get:
      summary: 'Retrieves the course details for given course ID and user ID'
      operationId: retrievesTheCourseDetailsForGivenCourseIDAndUserID
      description: ''
      parameters:
        -
          in: query
          name: userId
          description: 'ID of the user.'
          example: '3'
          required: true
          schema:
            type: string
            description: 'ID of the user.'
            example: '3'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'course 1'
                  course_id: 1
                  userId: 3
                  userName: 'John Doe'
                  email: john@example.com
                  featuredImageUrl: null
                  status: 'Not Started'
                  completionPercentage: 0
                  enrollmentDate: '2020-08-03T10:00:00.000000Z'
                  expiryDate: '2020-08-04T10:00:00.000000Z'
                  completionDate: null
                  startDate: null
                  lastAccessed: null
                  modules:
                    -
                      module_id: 1
                      name: test
                      slug: test
                      type: text
                      icon: '<i class="el-icon-tickets"></i>'
                      status_row_id: -1
                      status: 'Not Started'
                      started_on: null
                      completed_on: null
                      last_accessed_on: null
                      total_time_spent: null
                      completion_percentage: 0
                      no_of_times_accessed: 0
                      totalMarks: null
                      obtainedMarks: null
                    -
                      module_id: 4
                      name: assign
                      slug: assign
                      type: assignment
                      icon: '<i class="el-icon-edit-outline"></i>'
                      status_row_id: -1
                      status: 'Not Started'
                      started_on: null
                      completed_on: null
                      last_accessed_on: null
                      total_time_spent: null
                      completion_percentage: 0
                      no_of_times_accessed: 0
                      totalMarks: 50
                      obtainedMarks: null
                  hasSection: false
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'course 1'
                  course_id:
                    type: integer
                    example: 1
                  userId:
                    type: integer
                    example: 3
                  userName:
                    type: string
                    example: 'John Doe'
                  email:
                    type: string
                    example: john@example.com
                  featuredImageUrl:
                    type: string
                    example: null
                  status:
                    type: string
                    example: 'Not Started'
                  completionPercentage:
                    type: integer
                    example: 0
                  enrollmentDate:
                    type: string
                    example: '2020-08-03T10:00:00.000000Z'
                  expiryDate:
                    type: string
                    example: '2020-08-04T10:00:00.000000Z'
                  completionDate:
                    type: string
                    example: null
                  startDate:
                    type: string
                    example: null
                  lastAccessed:
                    type: string
                    example: null
                  modules:
                    type: array
                    example:
                      -
                        module_id: 1
                        name: test
                        slug: test
                        type: text
                        icon: '<i class="el-icon-tickets"></i>'
                        status_row_id: -1
                        status: 'Not Started'
                        started_on: null
                        completed_on: null
                        last_accessed_on: null
                        total_time_spent: null
                        completion_percentage: 0
                        no_of_times_accessed: 0
                        totalMarks: null
                        obtainedMarks: null
                      -
                        module_id: 4
                        name: assign
                        slug: assign
                        type: assignment
                        icon: '<i class="el-icon-edit-outline"></i>'
                        status_row_id: -1
                        status: 'Not Started'
                        started_on: null
                        completed_on: null
                        last_accessed_on: null
                        total_time_spent: null
                        completion_percentage: 0
                        no_of_times_accessed: 0
                        totalMarks: 50
                        obtainedMarks: null
                    items:
                      type: object
                      properties:
                        module_id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: test
                        slug:
                          type: string
                          example: test
                        type:
                          type: string
                          example: text
                        icon:
                          type: string
                          example: '<i class="el-icon-tickets"></i>'
                        status_row_id:
                          type: integer
                          example: -1
                        status:
                          type: string
                          example: 'Not Started'
                        started_on:
                          type: string
                          example: null
                        completed_on:
                          type: string
                          example: null
                        last_accessed_on:
                          type: string
                          example: null
                        total_time_spent:
                          type: string
                          example: null
                        completion_percentage:
                          type: integer
                          example: 0
                        no_of_times_accessed:
                          type: integer
                          example: 0
                        totalMarks:
                          type: string
                          example: null
                        obtainedMarks:
                          type: string
                          example: null
                  hasSection:
                    type: boolean
                    example: false
      tags:
        - Courses
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'Course registration ID for the student of the course you want to see progress.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/course-progress/update/{id}':
    put:
      summary: 'Update Course Progress'
      operationId: updateCourseProgress
      description: 'Updates the course progress for given course.'
      parameters:
        -
          in: query
          name: userId
          description: 'The ID of the user.'
          example: '3'
          required: false
          schema:
            type: string
            description: 'The ID of the user.'
            example: '3'
        -
          in: query
          name: enrollmentDate
          description: 'The enrollment date for the course. Format Y-m-d H:i:s.'
          example: '2020-01-01 00:00:00'
          required: false
          schema:
            type: string
            description: 'The enrollment date for the course. Format Y-m-d H:i:s.'
            example: '2020-01-01 00:00:00'
        -
          in: query
          name: expiryDate
          description: 'The expiry date for the course. Format Y-m-d H:i:s.'
          example: '2020-01-01 00:00:00'
          required: false
          schema:
            type: string
            description: 'The expiry date for the course. Format Y-m-d H:i:s.'
            example: '2020-01-01 00:00:00'
        -
          in: query
          name: startDate
          description: 'The start date for the course. Format Y-m-d H:i:s.'
          example: '2020-01-01 00:00:00'
          required: false
          schema:
            type: string
            description: 'The start date for the course. Format Y-m-d H:i:s.'
            example: '2020-01-01 00:00:00'
        -
          in: query
          name: completionDate
          description: 'The completion date for the course. Format Y-m-d H:i:s.'
          example: '2020-01-01 00:00:00'
          required: false
          schema:
            type: string
            description: 'The completion date for the course. Format Y-m-d H:i:s.'
            example: '2020-01-01 00:00:00'
        -
          in: query
          name: lastAccessed
          description: 'The last accessed date for the course. Format Y-m-d H:i:s.'
          example: '2020-01-01 00:00:00'
          required: false
          schema:
            type: string
            description: 'The last accessed date for the course. Format Y-m-d H:i:s.'
            example: '2020-01-01 00:00:00'
        -
          in: query
          name: status
          description: 'The status of the course.'
          example: Completed
          required: false
          schema:
            type: string
            description: 'The status of the course.'
            example: Completed
        -
          in: query
          name: modules
          description: 'The modules status for the course.'
          example: '[{"module_id": 16, "status": "Not Started"}]'
          required: false
          schema:
            type: string
            description: 'The modules status for the course.'
            example: '[{"module_id": 16, "status": "Not Started"}]'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Course updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Course updated Successfully'
      tags:
        - Courses
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'Optional parameter. The The ID of the course.'
        required: true
        schema:
          type: string
        examples:
          omitted:
            summary: 'When the value is omitted'
            value: ''
          present:
            summary: 'When the value is present'
            value: '6'
  '/api/course/name/{id}':
    get:
      summary: 'Retrieves the name of the course for given course ID'
      operationId: retrievesTheNameOfTheCourseForGivenCourseID
      description: ''
      parameters:
        -
          in: query
          name: id
          description: 'The ID of course.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of course.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: 'string Course name'
      tags:
        - Courses
      security: []
  '/api/course/enroll/{id}':
    post:
      summary: 'Enroll learners'
      operationId: enrollLearners
      description: 'To enroll users in a course, you need to use this request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '2 student(s) enrolled successfully'
                  enrolledUsersCount: 2
                  notEnrolledUsers: 0
                properties:
                  message:
                    type: string
                    example: '2 student(s) enrolled successfully'
                  enrolledUsersCount:
                    type: integer
                    example: 2
                  notEnrolledUsers:
                    type: integer
                    example: 0
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                studentIds:
                  type: array
                  description: 'User IDs needs to be enrolled in this course.'
                  example:
                    - 2
                    - 3
                  items:
                    type: string
                portalId:
                  type: integer
                  description: 'optional The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
                  example: 5
              required:
                - studentIds
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the course.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/course/remove/{id}':
    post:
      summary: 'Remove Learners'
      operationId: removeLearners
      description: 'To remove users from a course, you need to use this request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '2 student(s) removed successfully'
                properties:
                  message:
                    type: string
                    example: '2 student(s) removed successfully'
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enrollmentIds:
                  type: array
                  description: 'Enrollment IDs needs to be removed from this course.'
                  example:
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - enrollmentIds
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the course.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/course/reset/{id}':
    post:
      summary: 'Reset Progress'
      operationId: resetProgress
      description: 'To reset the progress of students for course, you need to use this request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '2 student(s) progress is reset successfully'
                properties:
                  message:
                    type: string
                    example: '2 student(s) progress is reset successfully'
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enrollmentIds:
                  type: array
                  description: 'Enrollment IDs needs to be reset from this course.'
                  example:
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - enrollmentIds
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the course.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/course/revoke/{id}':
    put:
      summary: 'Revoke Access'
      operationId: revokeAccess
      description: 'To revoke the access of course from students, you need to use this request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '2 learner(s) access has been revoked successfully'
                properties:
                  message:
                    type: string
                    example: '2 learner(s) access has been revoked successfully'
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enrollmentIds:
                  type: array
                  description: 'Course Registration/Enrollment IDs whose access needs to be revoked.'
                  example:
                    - 8
                    - 7
                  items:
                    type: string
              required:
                - enrollmentIds
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the course.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/course/grant/{id}':
    put:
      summary: 'Grant Access'
      operationId: grantAccess
      description: 'To grant the access of course to students, you need to use this request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '2 learner(s) access has been granted successfully'
                properties:
                  message:
                    type: string
                    example: '2 learner(s) access has been granted successfully'
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enrollmentIds:
                  type: array
                  description: 'Course Registration/Enrollment IDs needs access to be granted from this course.'
                  example:
                    - 9
                    - 6
                  items:
                    type: string
              required:
                - enrollmentIds
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the course.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/course/setExpiry/{id}':
    put:
      summary: 'Set Expiry'
      operationId: setExpiry
      description: 'To update the expiry date for the learners of a course, you need to use this request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Expiration date is successfully updated for 2 student(s)'
                properties:
                  message:
                    type: string
                    example: 'Expiration date is successfully updated for 2 student(s)'
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enrollmentIds:
                  type: array
                  description: 'Course Registration/Enrollment IDs needs setting expiry date for course.'
                  example:
                    - fugiat
                  items:
                    type: string
                expiryDate:
                  type: required
                  description: 'Date on which the course is going to be expired.'
                  example: porro
              required:
                - enrollmentIds
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the course.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/course/assignCertificate/{id}':
    post:
      summary: 'Assign Certificate'
      operationId: assignCertificate
      description: 'To assign certificate to the user for the course, you need to use this request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Certificate is successfully assigned to 2 student(s)'
                properties:
                  message:
                    type: string
                    example: 'Certificate is successfully assigned to 2 student(s)'
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enrollmentIds:
                  type: array
                  description: 'Course Registration/Enrollment IDs needs certificate to be assigned for this course.'
                  example:
                    - qui
                  items:
                    type: string
              required:
                - enrollmentIds
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the course.'
        example: '1'
        required: true
        schema:
          type: string
  /api/activities/verb/lookup:
    get:
      summary: 'Course Activity Lookup'
      operationId: courseActivityLookup
      description: "Retrieves all the activities performed in a course.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: ENROLLED
                    display_value: ENROLLED
                  -
                    db_value: STARTED
                    display_value: STARTED
                  -
                    db_value: ACCESSED
                    display_value: ACCESSED
                  -
                    db_value: COMPLETED
                    display_value: COMPLETED
                  -
                    db_value: SUBMITTED
                    display_value: SUBMITTED
                  -
                    db_value: EVALUATED
                    display_value: EVALUATED
                  -
                    db_value: REJECTED
                    display_value: REJECTED
                  -
                    db_value: RETAKE
                    display_value: RETAKEN
                  -
                    db_value: 'ACHIEVED CERTIFICATE'
                    display_value: 'ACHIEVED CERTIFICATE'
                  -
                    db_value: RESET
                    display_value: RESET
                  -
                    db_value: REMOVED
                    display_value: REMOVED
                  -
                    db_value: REVOKED
                    display_value: REVOKED
                  -
                    db_value: GRANTED
                    display_value: GRANTED
                  -
                    db_value: 'UPDATED EXPIRY DATE'
                    display_value: 'UPDATED EXPIRY DATE'
                  -
                    db_value: FAILED
                    display_value: FAILED
                  -
                    db_value: 'MANUALLY UPDATED'
                    display_value: 'MANUALLY UPDATED'
                  -
                    db_value: REGISTERED
                    display_value: REGISTERED
                  -
                    db_value: ATTENDED
                    display_value: ATTENDED
                  -
                    db_value: 'NO SHOW'
                    display_value: 'NO SHOW'
                  -
                    db_value: CANCELLED
                    display_value: CANCELLED
                  -
                    db_value: 'ACHIEVED BADGE'
                    display_value: 'ACHIEVED BADGE'
      tags:
        - Courses
      security: []
  '/api/progress/course/{id}':
    get:
      summary: 'Gradebook Data'
      operationId: gradebookData
      description: "Retrieves all the progress achieved by a learner on the course. Details will be returned in paginated mode.\nYou can use the userId parameter to get details for different Learners."
      parameters:
        -
          in: query
          name: userId
          description: 'ID of the user.'
          example: '3'
          required: true
          schema:
            type: string
            description: 'ID of the user.'
            example: '3'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'course 1'
                  modules:
                    -
                      module_id: 1
                      name: test
                      slug: test
                      type: text
                      icon: '<i class="el-icon-tickets"></i>'
                      status_row_id: 1
                      status: Completed
                      started_on: '2020-08-03T10:02:33.000000Z'
                      completed_on: '2020-08-03T10:02:41.000000Z'
                      last_accessed_on: '6 days ago'
                      total_time_spent:
                        hours: 0
                        minutes: 0
                        seconds: 6
                        totalSeconds: 6
                      completion_percentage: 100
                      no_of_times_accessed: 1
                      totalMarks: null
                      obtainedMarks: null
                    -
                      module_id: 4
                      name: assign
                      slug: assign
                      type: assignment
                      icon: '<i class="el-icon-edit-outline"></i>'
                      status_row_id: -1
                      status: 'Not Started'
                      started_on: ''
                      completed_on: ''
                      last_accessed_on: Never
                      total_time_spent: ''
                      points_awarded: ''
                      completion_percentage: 0
                      no_of_times_accessed: 0
                      totalMarks: 50
                      obtainedMarks: null
                  id: 1
                  userId: 3
                  permalink: 'http://localhost:8000/course/course-1'
                  featuredImageUrl: null
                  instructions: null
                  accessStatus: Allowed
                  status: Completed
                  completionPercentage: 50
                  timeSpent:
                    hours: 0
                    minutes: 0
                    seconds: 6
                    totalSeconds: 6
                  enrollmentDate: '03 Aug 2020'
                  isExpired: false
                  daysToExpire: 'Unlimited days'
                  lastAccessed: '6 days ago'
                  isCertificateAvailable: true
                  totalMarks: 50
                  obtainedMarks: 0
                  percentage: 0
                properties:
                  name:
                    type: string
                    example: 'course 1'
                  modules:
                    type: array
                    example:
                      -
                        module_id: 1
                        name: test
                        slug: test
                        type: text
                        icon: '<i class="el-icon-tickets"></i>'
                        status_row_id: 1
                        status: Completed
                        started_on: '2020-08-03T10:02:33.000000Z'
                        completed_on: '2020-08-03T10:02:41.000000Z'
                        last_accessed_on: '6 days ago'
                        total_time_spent:
                          hours: 0
                          minutes: 0
                          seconds: 6
                          totalSeconds: 6
                        completion_percentage: 100
                        no_of_times_accessed: 1
                        totalMarks: null
                        obtainedMarks: null
                      -
                        module_id: 4
                        name: assign
                        slug: assign
                        type: assignment
                        icon: '<i class="el-icon-edit-outline"></i>'
                        status_row_id: -1
                        status: 'Not Started'
                        started_on: ''
                        completed_on: ''
                        last_accessed_on: Never
                        total_time_spent: ''
                        points_awarded: ''
                        completion_percentage: 0
                        no_of_times_accessed: 0
                        totalMarks: 50
                        obtainedMarks: null
                    items:
                      type: object
                      properties:
                        module_id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: test
                        slug:
                          type: string
                          example: test
                        type:
                          type: string
                          example: text
                        icon:
                          type: string
                          example: '<i class="el-icon-tickets"></i>'
                        status_row_id:
                          type: integer
                          example: 1
                        status:
                          type: string
                          example: Completed
                        started_on:
                          type: string
                          example: '2020-08-03T10:02:33.000000Z'
                        completed_on:
                          type: string
                          example: '2020-08-03T10:02:41.000000Z'
                        last_accessed_on:
                          type: string
                          example: '6 days ago'
                        total_time_spent:
                          type: object
                          properties:
                            hours:
                              type: integer
                              example: 0
                            minutes:
                              type: integer
                              example: 0
                            seconds:
                              type: integer
                              example: 6
                            totalSeconds:
                              type: integer
                              example: 6
                        completion_percentage:
                          type: integer
                          example: 100
                        no_of_times_accessed:
                          type: integer
                          example: 1
                        totalMarks:
                          type: string
                          example: null
                        obtainedMarks:
                          type: string
                          example: null
                  id:
                    type: integer
                    example: 1
                  userId:
                    type: integer
                    example: 3
                  permalink:
                    type: string
                    example: 'http://localhost:8000/course/course-1'
                  featuredImageUrl:
                    type: string
                    example: null
                  instructions:
                    type: string
                    example: null
                  accessStatus:
                    type: string
                    example: Allowed
                  status:
                    type: string
                    example: Completed
                  completionPercentage:
                    type: integer
                    example: 50
                  timeSpent:
                    type: object
                    properties:
                      hours:
                        type: integer
                        example: 0
                      minutes:
                        type: integer
                        example: 0
                      seconds:
                        type: integer
                        example: 6
                      totalSeconds:
                        type: integer
                        example: 6
                  enrollmentDate:
                    type: string
                    example: '03 Aug 2020'
                  isExpired:
                    type: boolean
                    example: false
                  daysToExpire:
                    type: string
                    example: 'Unlimited days'
                  lastAccessed:
                    type: string
                    example: '6 days ago'
                  isCertificateAvailable:
                    type: boolean
                    example: true
                  totalMarks:
                    type: integer
                    example: 50
                  obtainedMarks:
                    type: integer
                    example: 0
                  percentage:
                    type: integer
                    example: 0
      tags:
        - Courses
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'Course registration ID for the Learner of the course you want to see progress.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/enrolled/course/{id}':
    get:
      summary: 'Enrolled User Lookup'
      operationId: enrolledUserLookup
      description: "Retrieves a list of users enrolled in a specified course, optionally filtered by portal ID\nand search term. The search term can match first name, last name, email, or full name."
      parameters:
        -
          in: query
          name: search_term
          description: 'The search term to search for users.'
          example: '"John Doe"'
          required: true
          schema:
            type: string
            description: 'The search term to search for users.'
            example: '"John Doe"'
        -
          in: query
          name: id
          description: 'The ID of the course to filter users by.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The ID of the course to filter users by.'
            example: 1
        -
          in: query
          name: portalId
          description: 'optional The ID of the portal to filter users by. Use -1 to skip portal filtering.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'optional The ID of the portal to filter users by. Use -1 to skip portal filtering.'
            example: 5
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    full_name: 'John Doe'
                    email: john@example.com
      tags:
        - Courses
      security: []
  /api/course/clone:
    post:
      summary: 'Clone a course.'
      operationId: cloneACourse
      description: "This function clones a course and its associated categories and modules.\nIt allows for a deep copy, which clones all course content, including modules and their details.\nThe cloned course will have a new name suffixed with \"_copy\" and the requesting user will be recorded as the creator and updater."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Course Cloned Successfully'
                properties:
                  message:
                    type: string
                    example: 'Course Cloned Successfully'
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                course_id:
                  type: integer
                  description: 'The ID of the course to clone.'
                  example: 1
                isDeepCopy:
                  type: boolean
                  description: 'If true, all content will be deeply copied.'
                  example: true
              required:
                - course_id
                - isDeepCopy
      security: []
  /api/courses/auto-enroll-courses/update:
    post:
      summary: 'Update the list of courses which are auto-enrolled for free to users after registration.'
      operationId: updateTheListOfCoursesWhichAreAutoEnrolledForFreeToUsersAfterRegistration
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Course Updated Successfully'
                  type: success
                  title: Success
                properties:
                  message:
                    type: string
                    example: 'Course Updated Successfully'
                  type:
                    type: string
                    example: success
                  title:
                    type: string
                    example: Success
      tags:
        - Courses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                courses:
                  type: array
                  description: 'The list of course IDs to auto enroll.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - courses
      security: []
  /api/courses/auto-enroll-courses:
    get:
      summary: 'Get the list of courses which are auto-enrolled for free to users after registration.'
      operationId: getTheListOfCoursesWhichAreAutoEnrolledForFreeToUsersAfterRegistration
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    value: 1
                    label: 'Course 1'
                  -
                    value: 2
                    label: 'Course 2'
                  -
                    value: 3
                    label: 'Course 3'
      tags:
        - Courses
      security: []
  /api/webinar/enrolled-students:
    get:
      summary: 'Retrieve the list of students enrolled in a given webinar'
      operationId: retrieveTheListOfStudentsEnrolledInAGivenWebinar
      description: "This API retrieves the list of students enrolled in a given webinar ID and portal ID.\nThe response includes the student name, email, avatar, status, registered on, last accessed on, attendance recording type, notes."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of records to return per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of records to return per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'The page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'Order by column and direction.'
          example: '{"colName": "name", "direction": "asc"}'
          required: false
          schema:
            type: string
            description: 'Order by column and direction.'
            example: '{"colName": "name", "direction": "asc"}'
        -
          in: query
          name: search_param
          description: 'JSON object containing search parameters.'
          example: '{}'
          required: false
          schema:
            type: string
            description: 'JSON object containing search parameters.'
            example: '{}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    user_id: 1
                    first_name: John
                    last_name: Doe
                    email: john@example.com
                    avatar: 'https://example.com/john.jpg'
                    status: active
                    registered_on: '2020-07-01 10:00:00'
                    last_accessed_on: '2020-07-01 11:00:00'
                    attendance_recording_type: video
                    notes: 'Some notes'
                  -
                    id: 2
                    user_id: 2
                    first_name: Jane
                    last_name: Smith
                    email: jane@example.com
                    avatar: 'https://example.com/jane.jpg'
                    status: inactive
                    registered_on: '2020-07-01 10:00:00'
                    last_accessed_on: '2020-07-01 11:00:00'
                    attendance_recording_type: audio
                    notes: 'Some notes'
      tags:
        - Courses
      security: []
    parameters:
      -
        in: path
        name: course_id
        description: 'The ID of the course to retrieve enrollments for.'
        example: '1'
        required: true
        schema:
          type: string
      -
        in: path
        name: webinar_id
        description: 'The ID of the webinar to retrieve enrollments for.'
        example: '1'
        required: true
        schema:
          type: string
      -
        in: path
        name: portal_id
        description: 'The ID of the portal for which the course is being accessed.'
        example: '1'
        required: true
        schema:
          type: string
  /api/courses/rating:
    post:
      summary: 'Save Course Rating'
      operationId: saveCourseRating
      description: 'Saves the course rating given by user and fires an event to send notification to the course creator.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "[\n    \"message\" => \"Course Rating submitted successfully.\"\n]"
      tags:
        - Courses
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                user_id:
                  type: required
                  description: 'The ID of the user who is submitting the review.'
                  example: '1'
                course_id:
                  type: required
                  description: 'The ID of the course for which the review is being submitted.'
                  example: '1'
                reviews:
                  type: string
                  description: 'The reviews given by the user.'
                  example: '"This course is awesome"'
                rating:
                  type: integer
                  description: 'The rating given by the user.'
                  example: 5
                display_name:
                  type: string
                  description: 'The display name of the user.'
                  example: '"John Doe"'
                portal_id:
                  type: required
                  description: 'The ID of the portal for which the course is being accessed.'
                  example: '1'
      security: []
  /api/course/ratings/listing:
    get:
      summary: 'Retrieves all the course ratings in a tabular list format in paginated mode.'
      operationId: retrievesAllTheCourseRatingsInATabularListFormatInPaginatedMode
      description: 'You can apply filter using search_param via associatedCourse(modules used in course) and moduleName.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"associatedCourse":"","moduleName":""}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"associatedCourse":"","moduleName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  total: 1
                  recordsFiltered: 1
                  ratings:
                    -
                      id: 1
                      courseName: 'Course Name'
                      courseId: 1
                      rating: 5
                      userId: 1
                      reviews: 'My first comment'
                      userdisplayName: 'John Doe'
                      submissionDate: 'Aug 11, 2020 05:56 AM'
                properties:
                  total:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  ratings:
                    type: array
                    example:
                      -
                        id: 1
                        courseName: 'Course Name'
                        courseId: 1
                        rating: 5
                        userId: 1
                        reviews: 'My first comment'
                        userdisplayName: 'John Doe'
                        submissionDate: 'Aug 11, 2020 05:56 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        courseName:
                          type: string
                          example: 'Course Name'
                        courseId:
                          type: integer
                          example: 1
                        rating:
                          type: integer
                          example: 5
                        userId:
                          type: integer
                          example: 1
                        reviews:
                          type: string
                          example: 'My first comment'
                        userdisplayName:
                          type: string
                          example: 'John Doe'
                        submissionDate:
                          type: string
                          example: 'Aug 11, 2020 05:56 AM'
      tags:
        - Courses
      security: []
  /api/course/ratings/delete:
    post:
      summary: 'Delete Course Rating'
      operationId: deleteCourseRating
      description: 'Deletes the specified course rating and updates the average rating of the course.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: success
                  message: 'Course Rating deleted successfully!'
                properties:
                  status:
                    type: string
                    example: success
                  message:
                    type: string
                    example: 'Course Rating deleted successfully!'
      tags:
        - Courses
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'The ID of the course rating to delete.'
                  example: '1'
      security: []
  /api/courses/launch:
    get:
      summary: Launch
      operationId: launch
      description: 'This API is used to launch a course and get the modules associated with the course.'
      parameters:
        -
          in: query
          name: info
          description: 'optional If the API is called with info parameter, the API will not start the course, but will return the information of the course.'
          example: info=true
          required: false
          schema:
            type: string
            description: 'optional If the API is called with info parameter, the API will not start the course, but will return the information of the course.'
            example: info=true
        -
          in: query
          name: portalId
          description: 'Portal ID of the user.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Portal ID of the user.'
            example: '1'
        -
          in: query
          name: moduleIds
          description: 'optional If you want to get the status of specific modules, you can pass the module IDs.'
          example:
            - 1
            - 2
          required: false
          schema:
            type: array
            description: 'optional If you want to get the status of specific modules, you can pass the module IDs.'
            example:
              - 1
              - 2
            items:
              type: string
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Course Name'
                  id: 2
                  permalink: 'http://example.com/course/launch'
                  featuredImageUrl: 'http://example.com/featured-image.jpg'
                  instructions: 'Course Instructions'
                  rating: 4.5
                  enableCourseRating: true
                  accessStatus: Allowed
                  status: 'Not Started'
                  display_status: 'Not Started'
                  completionPercentage: 0
                  timeSpent: '00:00:00'
                  enrollmentDate: 22-02-2022
                  isExpired: false
                  lastAccessed: Never
                  estimatedCompletionTime: '2 hours'
                  expireOn: 22-02-2022
                  modules: []
                  daysToExpire: 10
                properties:
                  name:
                    type: string
                    example: 'Course Name'
                  id:
                    type: integer
                    example: 2
                  permalink:
                    type: string
                    example: 'http://example.com/course/launch'
                  featuredImageUrl:
                    type: string
                    example: 'http://example.com/featured-image.jpg'
                  instructions:
                    type: string
                    example: 'Course Instructions'
                  rating:
                    type: number
                    example: 4.5
                  enableCourseRating:
                    type: boolean
                    example: true
                  accessStatus:
                    type: string
                    example: Allowed
                  status:
                    type: string
                    example: 'Not Started'
                  display_status:
                    type: string
                    example: 'Not Started'
                  completionPercentage:
                    type: integer
                    example: 0
                  timeSpent:
                    type: string
                    example: '00:00:00'
                  enrollmentDate:
                    type: string
                    example: 22-02-2022
                  isExpired:
                    type: boolean
                    example: false
                  lastAccessed:
                    type: string
                    example: Never
                  estimatedCompletionTime:
                    type: string
                    example: '2 hours'
                  expireOn:
                    type: string
                    example: 22-02-2022
                  modules:
                    type: array
                    example: []
                  daysToExpire:
                    type: integer
                    example: 10
      tags:
        - Courses
      security: []
    parameters:
      -
        in: path
        name: registrationId
        description: 'Registration ID of the course.'
        example: '2'
        required: true
        schema:
          type: string
  /api/courses/portalCourseInfo:
    get:
      summary: 'Retrieve course information (name, modules, webinars, etc.)'
      operationId: retrieveCourseInformationnameModulesWebinarsEtc
      description: "This API retrieves course information for a given course ID, portal ID, and user ID.\nThe response includes the course name, modules, webinars, learning resources, and other relevant information."
      parameters:
        -
          in: query
          name: courseId
          description: 'ID of the course.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the course.'
            example: '1'
        -
          in: query
          name: portalId
          description: 'ID of the portal for which the course is being accessed.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the portal for which the course is being accessed.'
            example: '1'
        -
          in: query
          name: userId
          description: 'ID of the user accessing the course.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the user accessing the course.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Course 1'
                  modules:
                    -
                      module_id: 1
                      name: 'Test Module 1'
                      slug: test-module-1
                      type: text
                      icon: el-icon-tickets
                      display_type: Text
                      last_accessed_on: Never
                      status: 'Not Enrolled'
                      display_status: 'Not Enrolled'
                      completion_percentage: 0
                      estimatedCompletion_time: '1 hour'
                  webinarList:
                    -
                      id: 1
                      name: 'Test Webinar 1'
                      start_date: '2020-08-03T10:02:33.000000Z'
                      end_date: '2020-08-03T10:02:33.000000Z'
                      description: 'Test webinar description'
                      duration: '1 hour'
                      is_registered: false
                  learningResources:
                    -
                      id: 1
                      name: 'Test Resource 1'
                      url: 'http://example.com/test-resource-1.pdf'
                      description: 'Test resource description'
                properties:
                  name:
                    type: string
                    example: 'Course 1'
                  modules:
                    type: array
                    example:
                      -
                        module_id: 1
                        name: 'Test Module 1'
                        slug: test-module-1
                        type: text
                        icon: el-icon-tickets
                        display_type: Text
                        last_accessed_on: Never
                        status: 'Not Enrolled'
                        display_status: 'Not Enrolled'
                        completion_percentage: 0
                        estimatedCompletion_time: '1 hour'
                    items:
                      type: object
                      properties:
                        module_id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Test Module 1'
                        slug:
                          type: string
                          example: test-module-1
                        type:
                          type: string
                          example: text
                        icon:
                          type: string
                          example: el-icon-tickets
                        display_type:
                          type: string
                          example: Text
                        last_accessed_on:
                          type: string
                          example: Never
                        status:
                          type: string
                          example: 'Not Enrolled'
                        display_status:
                          type: string
                          example: 'Not Enrolled'
                        completion_percentage:
                          type: integer
                          example: 0
                        estimatedCompletion_time:
                          type: string
                          example: '1 hour'
                  webinarList:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Test Webinar 1'
                        start_date: '2020-08-03T10:02:33.000000Z'
                        end_date: '2020-08-03T10:02:33.000000Z'
                        description: 'Test webinar description'
                        duration: '1 hour'
                        is_registered: false
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Test Webinar 1'
                        start_date:
                          type: string
                          example: '2020-08-03T10:02:33.000000Z'
                        end_date:
                          type: string
                          example: '2020-08-03T10:02:33.000000Z'
                        description:
                          type: string
                          example: 'Test webinar description'
                        duration:
                          type: string
                          example: '1 hour'
                        is_registered:
                          type: boolean
                          example: false
                  learningResources:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Test Resource 1'
                        url: 'http://example.com/test-resource-1.pdf'
                        description: 'Test resource description'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Test Resource 1'
                        url:
                          type: string
                          example: 'http://example.com/test-resource-1.pdf'
                        description:
                          type: string
                          example: 'Test resource description'
      tags:
        - Courses
      security: []
  /api/coupons/tabularlist:
    get:
      summary: 'Coupons Tabular List'
      operationId: couponsTabularList
      description: "Returns all the coupons in a tabular list format with pagination.\nAllows filtering using the search_param via code (coupon code)."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of items you want per page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of items you want per page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'optional JSON object for ordering items based on columns.'
          example: '{"colName":"created_at", "direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'optional JSON object for ordering items based on columns.'
            example: '{"colName":"created_at", "direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'optional JSON object for searching items based on coupon code.'
          example: 0
          required: false
          schema:
            type: integer
            description: 'optional JSON object for searching items based on coupon code.'
            example: 0
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      code: code75
                      type: percent_amount
                      value: 1500
                      total_limit: 12
                      expired_at: 'Aug 26, 2020'
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        code: code75
                        type: percent_amount
                        value: 1500
                        total_limit: 12
                        expired_at: 'Aug 26, 2020'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        code:
                          type: string
                          example: code75
                        type:
                          type: string
                          example: percent_amount
                        value:
                          type: integer
                          example: 1500
                        total_limit:
                          type: integer
                          example: 12
                        expired_at:
                          type: string
                          example: 'Aug 26, 2020'
      tags:
        - 'Discount Coupons'
      security: []
  /api/coupons/lookup:
    get:
      summary: 'Coupon Lookup'
      operationId: couponLookup
      description: "Retrieves all coupons whose code matches the search term provided.\nThis is useful for displaying coupons in form elements like dropdowns."
      parameters:
        -
          in: query
          name: search_term
          description: 'The term to search for in coupon codes.'
          example: '"SUMMER"'
          required: true
          schema:
            type: string
            description: 'The term to search for in coupon codes.'
            example: '"SUMMER"'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    code: code75
      tags:
        - 'Discount Coupons'
      security: []
  /api/coupons/type/lookup:
    get:
      summary: 'Retrieves all the type of the coupons.'
      operationId: retrievesAllTheTypeOfTheCoupons
      description: 'Helps showing options in form elements like dropdowns.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: fixed_amount
                    display_value: 'Fixed Cart Discount'
                  -
                    db_value: percent_amount
                    display_value: 'Percentage Discount'
      tags:
        - 'Discount Coupons'
      security: []
  /api/coupon/create:
    post:
      summary: 'Create Coupon'
      operationId: createCoupon
      description: 'Creates a coupon based on the request data. Coupons can be used by the students to get some discount while purchasing the course.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Coupon created successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Coupon created successfully'
      tags:
        - 'Discount Coupons'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                code:
                  type: string
                  description: 'code for the coupon.'
                  example: code75
                value:
                  type: numeric
                  description: 'Value of the coupon(discount price or percentage).'
                  example: '1500'
                type:
                  type: string
                  description: 'Types of the coupon. Type options: fixed_amount or percent_amount.'
                  example: percent_amount
                expiry:
                  type: date
                  description: 'On this date, this coupon will get expired.'
                  example: '2020-08-26'
                allowed_emails:
                  type: string
                  description: 'All allowed email comma seprated.'
                  example: 'null'
                usage_limit:
                  type: integer
                  description: 'How many times this coupon can be used?.'
                  example: 2000
                notes:
                  type: string
                  description: 'Notes for the coupon.'
                  example: 'Discount upto 75%'
                allowed_products:
                  type: array
                  description: 'allowed products.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                allowed_product_categories:
                  type: array
                  description: 'allowed product categories.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - code
                - value
                - type
      security: []
  '/api/coupon/{id}':
    get:
      summary: 'Get Coupon'
      operationId: getCoupon
      description: "Retrieves a coupon based on its ID. Useful for displaying a coupon's details."
      parameters:
        -
          in: query
          name: id
          description: 'The ID of the coupon.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of the coupon.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  code: code75
                  type: percent_amount
                  value: 1500
                  usage_limit: 12
                  expiry: '2020-08-26'
                  allowed_emails: null
                  note_privacy: null
                  notes: 'Discount upto 75%'
                  allowed_products: []
                  excluded_products: []
                  allowed_product_categories: []
                properties:
                  id:
                    type: integer
                    example: 1
                  code:
                    type: string
                    example: code75
                  type:
                    type: string
                    example: percent_amount
                  value:
                    type: integer
                    example: 1500
                  usage_limit:
                    type: integer
                    example: 12
                  expiry:
                    type: string
                    example: '2020-08-26'
                  allowed_emails:
                    type: string
                    example: null
                  note_privacy:
                    type: string
                    example: null
                  notes:
                    type: string
                    example: 'Discount upto 75%'
                  allowed_products:
                    type: array
                    example: []
                  excluded_products:
                    type: array
                    example: []
                  allowed_product_categories:
                    type: array
                    example: []
      tags:
        - 'Discount Coupons'
      security: []
    put:
      summary: 'Update Coupon'
      operationId: updateCoupon
      description: 'Updates a coupon based on the id provided as parameter.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Coupon updated successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Coupon updated successfully'
      tags:
        - 'Discount Coupons'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'The ID of the coupon.'
                  example: '1'
                code:
                  type: required
                  description: 'Code for the coupon.'
                  example: code75
                value:
                  type: required
                  description: 'Value of the coupon(discount price or percentage).'
                  example: '1500'
                type:
                  type: required
                  description: 'Types of the coupon. Type options: fixed_amount or percent_amount.'
                  example: percent_amount
                expiry:
                  type: date
                  description: 'On this date, this coupon will get expired.'
                  example: '2020-08-26'
                allowed_emails:
                  type: string
                  description: 'All allowed email comma seprated.'
                  example: 'null'
                usage_limit:
                  type: integer
                  description: 'How many times this coupon can be used?.'
                  example: 2000
                notes:
                  type: string
                  description: 'Notes for the coupon.'
                  example: 'Discount upto 75%'
                allowed_products:
                  type: array
                  description: 'allowed products.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                allowed_product_categories:
                  type: array
                  description: 'allowed product categories.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
      security: []
  /api/coupon/delete:
    post:
      summary: 'Delete Coupon'
      operationId: deleteCoupon
      description: 'Deletes a coupon based on the id provided as parameter.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '1 coupon(s) deleted. 1 coupon(s) not deleted as they are associated with orders'
                properties:
                  message:
                    type: string
                    example: '1 coupon(s) deleted. 1 coupon(s) not deleted as they are associated with orders'
        500:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Something went wrong'
                properties:
                  message:
                    type: string
                    example: 'Something went wrong'
      tags:
        - 'Discount Coupons'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: required
                  description: 'The ID of the coupon.'
                  example: '[1,2,3]'
      security: []
  /api/settings/coupon/list:
    get:
      summary: 'List of all coupons.'
      operationId: listOfAllCoupons
      description: 'Returns a list of all coupons. Response contains coupon id and coupon code.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  '0':
                    id: 1
                    code: code1
                  '1':
                    id: 2
                    code: code2
                properties:
                  -
                    type: object
                    properties:
                      id:
                        type: integer
                        example: 1
                      code:
                        type: string
                        example: code1
                  -
                    type: object
                    properties:
                      id:
                        type: integer
                        example: 2
                      code:
                        type: string
                        example: code2
        500:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Something went wrong'
                properties:
                  message:
                    type: string
                    example: 'Something went wrong'
      tags:
        - 'Discount Coupons'
      security: []
  /api/modules/discussion:
    get:
      summary: 'Discussion Modules Tabular List'
      operationId: discussionModulesTabularList
      description: "Returns all discussion modules in a tabular list format with pagination.\nFilters can be applied using search parameters for associated courses and module names."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of items per page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of items per page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number for pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number for pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'Optional JSON for sorting items by column.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'Optional JSON for sorting items by column.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'Optional JSON for searching by associatedCourse and moduleName.'
          example: '{"associatedCourse": "", "moduleName": ""}'
          required: false
          schema:
            type: string
            description: 'Optional JSON for searching by associatedCourse and moduleName.'
            example: '{"associatedCourse": "", "moduleName": ""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 5
                  records:
                    -
                      id: 1
                      name: 'Discussion 1'
                      slug: discussion-1
                      type: discussion
                      totalPoints: 100
                      icon: '<i class="el-icon-chat"></i>'
                      author: 'John Doe'
                      showMappedCourses: false
                      created_at: 'Aug 03, 2020 09:56 AM'
                      course_count: 2
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 5
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Discussion 1'
                        slug: discussion-1
                        type: discussion
                        totalPoints: 100
                        icon: '<i class="el-icon-chat"></i>'
                        author: 'John Doe'
                        showMappedCourses: false
                        created_at: 'Aug 03, 2020 09:56 AM'
                        course_count: 2
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Discussion 1'
                        slug:
                          type: string
                          example: discussion-1
                        type:
                          type: string
                          example: discussion
                        totalPoints:
                          type: integer
                          example: 100
                        icon:
                          type: string
                          example: '<i class="el-icon-chat"></i>'
                        author:
                          type: string
                          example: 'John Doe'
                        showMappedCourses:
                          type: boolean
                          example: false
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        course_count:
                          type: integer
                          example: 2
      tags:
        - Discussions
      security: []
    post:
      summary: 'Create Discussion Module'
      operationId: createDiscussionModule
      description: "To create a discussion module, you need to use this request. (See parameters)\nCreated discussion modules can be used in the course as course content/lesson.\n\nReturns : id of the discussion created and successfull message"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 8
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 8
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - Discussions
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the discussion module.'
                  example: First-discussion
                content:
                  type: string
                  description: 'Content for the discussion modules that learners will see.'
                  example: 'A brief description'
                should_be_evaluated:
                  type: boolean
                  description: 'If true, the discussion will be graded on course evaluation.'
                  example: true
                totalPoints:
                  type: integer
                  description: 'Total points a student can get by completing this discussion.'
                  example: 20
                minComments:
                  type: integer
                  description: 'At least these many comments should be provided by the student to pass the discussion(required if should_be_evaluated is true).'
                  example: 5
                estimatedCompletion:
                  type: nullable
                  description: 'Estimated time to complete the module.'
                  example: '90'
                estimationCompletedUnit:
                  type: nullable
                  description: 'Unit of time estimation (e.g., minutes, hours).'
                  example: minutes
              required:
                - name
                - content
                - should_be_evaluated
      security: []
  '/api/modules/discussion/{id}':
    put:
      summary: 'Update Discussion Module'
      operationId: updateDiscussionModule
      description: "Updates the details of a specified discussion module. Validates the request\nand updates the module with the given parameters if it exists."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Module updated successfully'
      tags:
        - Discussions
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the discussion module.'
                  example: 'First Discussion'
                content:
                  type: string
                  description: 'Content for the discussion module.'
                  example: 'An updated brief description'
                should_be_evaluated:
                  type: boolean
                  description: 'If true, the discussion will be graded on course evaluation.'
                  example: true
                totalPoints:
                  type: integer
                  description: 'optional Total points a student can get by completing this discussion.'
                  example: 20
                minComments:
                  type: integer
                  description: 'At least these many comments should be provided by the student to pass the discussion. Required if should_be_evaluated is true.'
                  example: 5
                estimatedCompletion:
                  type: nullable
                  description: 'Estimated time to complete the module.'
                  example: '90'
                estimationCompletedUnit:
                  type: nullable
                  description: 'Unit of time estimation (e.g., minutes, hours).'
                  example: minutes
              required:
                - name
                - content
                - should_be_evaluated
      security: []
    get:
      summary: 'Get Discussion Module'
      operationId: getDiscussionModule
      description: 'Returns a discussion module based on its ID.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'Discussion 1'
                  slug: discussion-1
                  content: 'A brief description'
                  totalPoints: 100
                  should_be_evaluated: true
                  minComments: 2
                  estimatedCompletion: 2
                  estimationCompletedUnit: hours
                  courses:
                    -
                      course_id: 1
                      course_name: 'Course 1'
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'Discussion 1'
                  slug:
                    type: string
                    example: discussion-1
                  content:
                    type: string
                    example: 'A brief description'
                  totalPoints:
                    type: integer
                    example: 100
                  should_be_evaluated:
                    type: boolean
                    example: true
                  minComments:
                    type: integer
                    example: 2
                  estimatedCompletion:
                    type: integer
                    example: 2
                  estimationCompletedUnit:
                    type: string
                    example: hours
                  courses:
                    type: array
                    example:
                      -
                        course_id: 1
                        course_name: 'Course 1'
                    items:
                      type: object
                      properties:
                        course_id:
                          type: integer
                          example: 1
                        course_name:
                          type: string
                          example: 'Course 1'
      tags:
        - Discussions
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the discussion module.'
        example: '1'
        required: true
        schema:
          type: string
  /api/module/discussion/details:
    get:
      summary: 'Get Discussion Module Details'
      operationId: getDiscussionModuleDetails
      description: 'To get the details of a discussion module, you need to use this request. (See parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n\"name\": \"First Discussion\",\n\"slug\": \"first-discussion\",\n\"content\": \"A brief description\",\n\"courseName\": \"First Course\",\n\"courseSlug\": \"http://localhost:8000/courses/1/launch\",\n\"url\": \"http://localhost:8000/courses/1/modules/2/launch\",\n\"totalPoints\": 20,\n\"shouldBeEvaluated\": true,\n\"min_time_spent\": 90,\n\"otherModules\": [],\n\"launchCheck\": {...},\n\"prevSlug\": \"first-video\",\n\"nextSlug\": \"second-video\",\n\"currentUserId\": 1,\n\"currentStudentAvatar\": \"http://localhost:8000/storage/avatars/1.png\",\n\"currentUserName\": \"John Doe\",\n\"status\": \"In Progress\",\n\"statusRowId\": 1,\n\"timeSpent\": 0,\n\"course_newly_completed\": false,\n\"timeToBeSpent\": 1,\n\"instructorResponse\": null\n}"
      tags:
        - Discussions
      security: []
    parameters:
      -
        in: path
        name: registrationId
        description: 'ID of the course registration.'
        example: '1'
        required: true
        schema:
          type: string
      -
        in: path
        name: moduleId
        description: 'ID of the discussion module.'
        example: '2'
        required: true
        schema:
          type: string
      -
        in: path
        name: portalId
        description: 'Optional parameter. The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
        required: true
        schema:
          type: integer
        examples:
          omitted:
            summary: 'When the value is omitted'
            value: ''
          present:
            summary: 'When the value is present'
            value: 5
  /api/module/discussion/loadComments:
    get:
      summary: 'Retrieve Comments'
      operationId: retrieveComments
      description: "Returns all the discussion comments in a tabular list format in paginated mode.\nYou can apply filter using search_param via associatedCourse(modules used in course) and moduleName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"associatedCourse":"","moduleName":""}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"associatedCourse":"","moduleName":""}'
        -
          in: query
          name: moduleId
          description: 'ID of the discussion module.'
          example: '2'
          required: true
          schema:
            type: string
            description: 'ID of the discussion module.'
            example: '2'
        -
          in: query
          name: registrationId
          description: 'ID of the course registration.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the course registration.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: '{"recordsTotal":1,"recordsFiltered":1,"records":[{"id":1,"comment":"My first comment","userAvatar":"<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"40\" height=\"40\" viewBox=\"0 0 40 40\"><circle cx=\"20\" cy=\"20\" r=\"20\" stroke=\"background\" stroke-width=\"0\" fill=\"#00BCD4\" \/><text x=\"20\" y=\"20\" font-size=\"14\" fill=\"#FFFFFF\" alignment-baseline=\"middle\" text-anchor=\"middle\" dominant-baseline=\"central\">AS<\/text><\/svg>","userFullName":"Aom Staff","date":"Aug 11, 2020 05:56 AM", "replies":[]}]'
      tags:
        - Discussions
      security: []
  /api/module/discussion/postComment:
    post:
      summary: 'Post Comment for Discussion Module'
      operationId: postCommentForDiscussionModule
      description: "Post a comment for the discussion module. The comment is for the given module under the given course registration.\nIf the comment meets the submission conditions, then the module status is updated to 'Submitted' and an entry is made in discussion evaluation table and an email is sent to the instructor."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: Submitted
                  message: 'Comment Posted'
                properties:
                  status:
                    type: string
                    example: Submitted
                  message:
                    type: string
                    example: 'Comment Posted'
      tags:
        - Discussions
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                statusRowId:
                  type: required
                  description: 'ID of the Module status of the current discussion submission.'
                  example: '7'
                currentUserId:
                  type: required
                  description: 'ID of the user who commented.'
                  example: '1'
                comment:
                  type: required
                  description: 'Comment posted by the user for current discussion.'
                  example: 'This is my first comment.'
                parentId:
                  type: optional
                  description: 'Parent ID of the discussion.'
                  example: '1'
                portalId:
                  type: integer
                  description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
                  example: 5
      security: []
  /api/module/discussion/submissions:
    get:
      summary: 'Retrieve Discussion Submission Details'
      operationId: retrieveDiscussionSubmissionDetails
      description: 'Retrieves the submission details of the discussion the student have given. Helps in grading a student. (See Response)'
      parameters:
        -
          in: query
          name: statusRowId
          description: 'ID of the Module status of the current discussion submission. example: 1'
          example: delectus
          required: true
          schema:
            type: string
            description: 'ID of the Module status of the current discussion submission. example: 1'
            example: delectus
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  courseId: 1
                  courseName: 'course 1'
                  discussionName: assign
                  status: 'In Progress'
                  content: Desc
                  totalPoints: 50
                  shouldBeEvaluated: true
                  userAvatar: avatar.jpg
                  userFullName: 'Aom Staff'
                  userEmail: aomstaff@staff.com
                  comments:
                    -
                      id: 1
                      comment: 'This is my first comment.'
                      date: 'Aug 10, 2020 11:33 AM'
                  replies:
                    -
                      id: 1
                      comment: 'This is my first reply.'
                      date: 'Aug 10, 2020 11:33 AM'
                properties:
                  courseId:
                    type: integer
                    example: 1
                  courseName:
                    type: string
                    example: 'course 1'
                  discussionName:
                    type: string
                    example: assign
                  status:
                    type: string
                    example: 'In Progress'
                  content:
                    type: string
                    example: Desc
                  totalPoints:
                    type: integer
                    example: 50
                  shouldBeEvaluated:
                    type: boolean
                    example: true
                  userAvatar:
                    type: string
                    example: avatar.jpg
                  userFullName:
                    type: string
                    example: 'Aom Staff'
                  userEmail:
                    type: string
                    example: aomstaff@staff.com
                  comments:
                    type: array
                    example:
                      -
                        id: 1
                        comment: 'This is my first comment.'
                        date: 'Aug 10, 2020 11:33 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        comment:
                          type: string
                          example: 'This is my first comment.'
                        date:
                          type: string
                          example: 'Aug 10, 2020 11:33 AM'
                  replies:
                    type: array
                    example:
                      -
                        id: 1
                        comment: 'This is my first reply.'
                        date: 'Aug 10, 2020 11:33 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        comment:
                          type: string
                          example: 'This is my first reply.'
                        date:
                          type: string
                          example: 'Aug 10, 2020 11:33 AM'
      tags:
        - Discussions
      security: []
  /api/module/discussion/evaluate:
    post:
      summary: 'Evaluate Discussion'
      operationId: evaluateDiscussion
      description: "Evaluates the discussion from Instructor side.Updates the status of discussion to completed if Instructor thinks student's submission is upto the marks.\n(See Parameters)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Discussion evaluated successfully'
                properties:
                  message:
                    type: string
                    example: 'Discussion evaluated successfully'
      tags:
        - Discussions
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'ID of the portal for which the assignment is being submitted.'
                  example: 1
                statusRowId:
                  type: required
                  description: 'ID of the Module status of the current assignment.'
                  example: '7'
                evaluation:
                  type: required
                  description: 'Evaluation data by the Instructor(Completed or not).'
                  example: "{instructorMessage : 'You comments look good', pointsAwarded: '50' }"
      security: []
  /api/module/discussion/comments:
    get:
      summary: 'Retrieve Discussion Comments'
      operationId: retrieveDiscussionComments
      description: "Retrieves all the discussion comments in a nested tree format in paginated mode.\nYou can apply filter using search_param via associatedCourse(modules used in course) and moduleName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"associatedCourse":"","moduleName":""}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"associatedCourse":"","moduleName":""}'
        -
          in: query
          name: moduleId
          description: 'ID of the discussion module.'
          example: '2'
          required: true
          schema:
            type: string
            description: 'ID of the discussion module.'
            example: '2'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      comment: 'My first comment'
                      courseName: 'course 1'
                      userAvatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                      userFullName: 'Aom Staff'
                      date: 'Aug 11, 2020 05:56 AM'
                      replies:
                        -
                          id: 1
                          comment: 'My first reply'
                          userAvatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                          userFullName: 'Aom Staff'
                          date: 'Aug 11, 2020 05:56 AM'
                          replies:
                            -
                              id: 1
                              comment: 'My second reply'
                              userAvatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                              userFullName: 'Aom Staff'
                              date: 'Aug 11, 2020 05:56 AM'
                              replies: []
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        comment: 'My first comment'
                        courseName: 'course 1'
                        userAvatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                        userFullName: 'Aom Staff'
                        date: 'Aug 11, 2020 05:56 AM'
                        replies:
                          -
                            id: 1
                            comment: 'My first reply'
                            userAvatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                            userFullName: 'Aom Staff'
                            date: 'Aug 11, 2020 05:56 AM'
                            replies:
                              -
                                id: 1
                                comment: 'My second reply'
                                userAvatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                                userFullName: 'Aom Staff'
                                date: 'Aug 11, 2020 05:56 AM'
                                replies: []
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        comment:
                          type: string
                          example: 'My first comment'
                        courseName:
                          type: string
                          example: 'course 1'
                        userAvatar:
                          type: string
                          example: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                        userFullName:
                          type: string
                          example: 'Aom Staff'
                        date:
                          type: string
                          example: 'Aug 11, 2020 05:56 AM'
                        replies:
                          type: array
                          example:
                            -
                              id: 1
                              comment: 'My first reply'
                              userAvatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                              userFullName: 'Aom Staff'
                              date: 'Aug 11, 2020 05:56 AM'
                              replies:
                                -
                                  id: 1
                                  comment: 'My second reply'
                                  userAvatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                                  userFullName: 'Aom Staff'
                                  date: 'Aug 11, 2020 05:56 AM'
                                  replies: []
                          items:
                            type: object
                            properties:
                              id:
                                type: integer
                                example: 1
                              comment:
                                type: string
                                example: 'My first reply'
                              userAvatar:
                                type: string
                                example: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                              userFullName:
                                type: string
                                example: 'Aom Staff'
                              date:
                                type: string
                                example: 'Aug 11, 2020 05:56 AM'
                              replies:
                                type: array
                                example:
                                  -
                                    id: 1
                                    comment: 'My second reply'
                                    userAvatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                                    userFullName: 'Aom Staff'
                                    date: 'Aug 11, 2020 05:56 AM'
                                    replies: []
                                items:
                                  type: object
                                  properties:
                                    id:
                                      type: integer
                                      example: 1
                                    comment:
                                      type: string
                                      example: 'My second reply'
                                    userAvatar:
                                      type: string
                                      example: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#00BCD4" /><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">AS</text></svg>'
                                    userFullName:
                                      type: string
                                      example: 'Aom Staff'
                                    date:
                                      type: string
                                      example: 'Aug 11, 2020 05:56 AM'
                                    replies:
                                      type: array
                                      example: []
      tags:
        - Discussions
      security: []
  /api/module/discussion/deleteComments:
    post:
      summary: 'Delete Discussion Comments'
      operationId: deleteDiscussionComments
      description: 'Deletes the given comments and its children too.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Comment(s) deleted successfully'
                properties:
                  message:
                    type: string
                    example: 'Comment(s) deleted successfully'
      tags:
        - Discussions
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: required
                  description: 'An array of IDs of comments to be deleted.'
                  example: '[1,2,3]'
      security: []
  /api/settings/ecommerce/global:
    get:
      summary: 'Retrieves the global ecommerce product settings.'
      operationId: retrievesTheGlobalEcommerceProductSettings
      description: 'Fetches the settings of global products, including the color of product price and call to action names for free, simple and subscription products.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  product_price_color:
                    content:
                      backgroundColor: '#fff'
                  free_product_cta: 'Enroll Now'
                  simple_product_cta: 'Add to Cart'
                  subscription_product_cta: Subscribe
                properties:
                  product_price_color:
                    type: object
                    properties:
                      content:
                        type: object
                        properties:
                          backgroundColor:
                            type: string
                            example: '#fff'
                  free_product_cta:
                    type: string
                    example: 'Enroll Now'
                  simple_product_cta:
                    type: string
                    example: 'Add to Cart'
                  subscription_product_cta:
                    type: string
                    example: Subscribe
      tags:
        - ECommerce
      security: []
    put:
      summary: 'Set Global Ecommerce Product Settings'
      operationId: setGlobalEcommerceProductSettings
      description: 'Updates the settings of global products, including the color of product price and call to action names for free, simple and subscription products.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                freeProductCta:
                  type: string
                  description: 'Call to action name for free products.'
                  example: 'Enroll Now'
                simpleProductCta:
                  type: string
                  description: 'Call to action name for simple products.'
                  example: 'Add to Cart'
                subscriptionProductCta:
                  type: string
                  description: 'Call to action name for subscription products.'
                  example: Subscribe
                productPriceColor:
                  type: object
                  description: 'Object containing a single key "content" with a single key "backgroundColor" which is the color of the product price.'
                  example:
                    content:
                      backgroundColor: '#fff'
                  properties: {  }
              required:
                - freeProductCta
                - simpleProductCta
                - subscriptionProductCta
                - productPriceColor
      security: []
  /api/settings/ecommerce/cartAbandonment:
    get:
      summary: 'Retrieve Ecommerce Cart Abandonment Settings'
      operationId: retrieveEcommerceCartAbandonmentSettings
      description: "Fetches the settings related to cart abandonment tracking, including\nwhether tracking is enabled and the UTM parameters used for tracking."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  enable_cart_abandoned_tracking: true
                  enable_tracking_staff: false
                  utm_parameters: 'utm_source=google&utm_medium=cpc'
                properties:
                  enable_cart_abandoned_tracking:
                    type: boolean
                    example: true
                  enable_tracking_staff:
                    type: boolean
                    example: false
                  utm_parameters:
                    type: string
                    example: 'utm_source=google&utm_medium=cpc'
      tags:
        - ECommerce
      security: []
    put:
      summary: 'Set Ecommerce Cart Abandonment Setting'
      operationId: setEcommerceCartAbandonmentSetting
      description: "Updates the ecommerce settings related to cart abandonment tracking.\nAllows enabling/disabling of cart abandonment tracking and tracking by staff.\nAlso updates UTM parameters used for tracking."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Cart Settings Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Cart Settings Updated Successfully'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enableTracking:
                  type: boolean
                  description: 'Enable or disable cart abandonment tracking.'
                  example: true
                enableTrackingStaff:
                  type: boolean
                  description: 'Enable or disable tracking by staff.'
                  example: false
                utmParameters:
                  type: string
                  description: 'UTM parameters for cart abandonment tracking.'
                  example: 'utm_source=google&utm_medium=cpc'
              required:
                - enableTracking
                - enableTrackingStaff
      security: []
  /api/countries/lookup:
    get:
      summary: 'Country Lookup'
      operationId: countryLookup
      description: 'Retrieves all the countries in list format. Helps while showing countries in form elements like dropdown.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  AF: Afghanistan
                  AX: 'Aland Islands'
                  AL: Albania
                  DZ: Algeria
                  AS: 'American Samoa'
                  AD: Andorra
                  AO: Angola
                  AI: Anguilla
                  AQ: Antarctica
                  AG: 'Antigua and Barbuda'
                  AR: Argentina
                  AM: Armenia
                  AW: Aruba
                  AU: Australia
                  AT: Austria
                  AZ: Azerbaijan
                  BS: Bahamas
                  BH: Bahrain
                  BD: Bangladesh
                  BB: Barbados
                  BY: Belarus
                  BE: Belgium
                  BZ: Belize
                  BJ: Benin
                  BM: Bermuda
                  BT: Bhutan
                  BO: Bolivia
                  BA: 'Bosnia and Herzegovina'
                  BW: Botswana
                  BV: 'Bouvet Island'
                  BR: Brazil
                  VG: 'Virgin Islands, British'
                  BN: Brunei
                  BG: Bulgaria
                  BF: 'Burkina Faso'
                  BI: Burundi
                  KH: Cambodia
                  CM: Cameroon
                  CA: Canada
                  CV: 'Cape Verde'
                  KY: 'Cayman Islands'
                  CF: 'Central African Republic'
                  TD: Chad
                  CL: Chile
                  CN: China
                  CX: 'Christmas Island'
                  CC: 'Cocos (Keeling) Islands'
                  CO: Colombia
                  KM: Comoros
                  CG: Congo
                  CD: 'Congo, The Democratic Republic of the'
                  CK: 'Cook Islands'
                  CR: 'Costa Rica'
                  CI: "Cote d'Ivoire"
                  HR: Croatia
                  CU: Cuba
                  CW: Curacao
                  CY: Cyprus
                  CZ: 'Czech Republic'
                  DK: Denmark
                  DJ: Djibouti
                  DM: Dominica
                  DO: 'Dominican Republic'
                  EC: Ecuador
                  EG: Egypt
                  SV: 'El Salvador'
                  GQ: 'Equatorial Guinea'
                  ER: Eritrea
                  EE: Estonia
                  ET: Ethiopia
                  FK: 'Falkland Islands (Malvinas)'
                  FO: 'Faroe Islands'
                  FJ: Fiji
                  FI: Finland
                  FR: France
                  GF: 'French Guiana'
                  PF: 'French Polynesia'
                  TF: 'French Southern Territories'
                  GA: Gabon
                  GM: Gambia
                  GE: Georgia
                  DE: Germany
                  GH: Ghana
                  GI: Gibraltar
                  GR: Greece
                  GL: Greenland
                  GD: Grenada
                  GP: Guadeloupe
                  GU: Guam
                  GT: Guatemala
                  GG: Guernsey
                  GN: Guinea
                  GW: Guinea-Bissau
                  GY: Guyana
                  HT: Haiti
                  HM: 'Heard Island and McDonald Islands'
                  VA: 'Holy See (Vatican City)'
                  HN: Honduras
                  HK: 'Hong Kong'
                  HU: Hungary
                  IS: Iceland
                  IN: India
                  ID: Indonesia
                  IR: 'Iran, Islamic Republic of'
                  IQ: Iraq
                  IE: Ireland
                  IM: 'Isle of Man'
                  IL: Israel
                  IT: Italy
                  JM: Jamaica
                  JP: Japan
                  JE: Jersey
                  JO: Jordan
                  KZ: Kazakhstan
                  KE: Kenya
                  KI: Kiribati
                  KP: "Korea, Democratic People's Republic of"
                  KR: 'Korea, Republic of'
                  KW: Kuwait
                  KG: Kyrgyzstan
                  LA: "Lao People's Democratic Republic"
                  LV: Latvia
                  LB: Lebanon
                  LS: Lesotho
                  LR: Liberia
                  LY: 'Libyan Arab Jamahiriya'
                  LT: Lithuania
                  LU: Luxembourg
                  MO: Macao
                  MK: 'Macedonia, The Former Yugoslav Republic of'
                  MG: Madagascar
                  MW: Malawi
                  MY: Malaysia
                  MV: Maldives
                  ML: Mali
                  MT: Malta
                  MH: 'Marshall Islands'
                  MQ: Martinique
                  MR: Mauritania
                  MU: Mauritius
                  YT: Mayotte
                  MX: Mexico
                  FM: 'Micronesia, Federated States of'
                  MD: 'Moldova, Republic of'
                  MC: Monaco
                  MN: Mongolia
                  ME: Montenegro
                  MS: Montserrat
                  MA: Morocco
                  MZ: Mozambique
                  MM: Myanmar
                  NA: Namibia
                  NR: Nauru
                  NP: Nepal
                  NL: Netherlands
                  NC: 'New Caledonia'
                  NZ: 'New Zealand'
                  NI: Nicaragua
                  NE: Niger
                  NG: Nigeria
                  NU: Niue
                  NF: 'Norfolk Island'
                  MP: 'Northern Mariana Islands'
                  'NO': Norway
                  OM: Oman
                  PK: Pakistan
                  PW: Palau
                  PS: 'Palestinian Territory, Occupied'
                  PA: Panama
                  PG: 'Papua New Guinea'
                  PY: Paraguay
                  PE: Peru
                  PH: Philippines
                  PN: Pitcairn
                  PL: Poland
                  PT: Portugal
                  PR: 'Puerto Rico'
                  QA: Qatar
                  RE: Reunion
                  RO: Romania
                  RU: 'Russian Federation'
                  RW: Rwanda
                  BL: 'Saint Barthelemy'
                  SH: 'Saint Helena, Ascension and Tristan da Cunha'
                  KN: 'Saint Kitts and Nevis'
                  LC: 'Saint Lucia'
                  MF: 'Saint Martin (French part)'
                  PM: 'Saint Pierre and Miquelon'
                  VC: 'Saint Vincent and the Grenadines'
                  WS: Samoa
                  SM: 'San Marino'
                  ST: 'Sao Tome and Principe'
                  SA: 'Saudi Arabia'
                  SN: Senegal
                  RS: Serbia
                  SC: Seychelles
                  SL: 'Sierra Leone'
                  SG: Singapore
                  SX: 'Sint Maarten (Dutch part)'
                  SK: Slovakia
                  SI: Slovenia
                  SB: 'Solomon Islands'
                  SO: Somalia
                  ZA: 'South Africa'
                  GS: 'South Georgia and the South Sandwich Islands'
                  SS: 'South Sudan'
                  ES: Spain
                  LK: 'Sri Lanka'
                  SD: Sudan
                  SR: Suriname
                  SJ: 'Svalbard and Jan Mayen'
                  SZ: Swaziland
                  SE: Sweden
                  CH: Switzerland
                  SY: 'Syrian Arab Republic'
                  TW: 'Taiwan, Province of China'
                  TJ: Tajikistan
                  TZ: 'Tanzania, United Republic of'
                  TH: Thailand
                  TL: Timor-Leste
                  TG: Togo
                  TK: Tokelau
                  TO: Tonga
                  TT: 'Trinidad and Tobago'
                  TN: Tunisia
                  TR: Turkey
                  TM: Turkmenistan
                  TC: 'Turks and Caicos Islands'
                  TV: Tuvalu
                  UG: Uganda
                  UA: Ukraine
                  AE: 'United Arab Emirates'
                  GB: 'United Kingdom'
                  US: 'United States'
                  UM: 'United States Minor Outlying Islands'
                  UY: Uruguay
                  UZ: Uzbekistan
                  VU: Vanuatu
                  VE: 'Venezuela, Bolivarian Republic of'
                  VN: 'Viet Nam'
                  VI: 'Virgin Islands, U.S.'
                  WF: 'Wallis and Futuna'
                  EH: 'Western Sahara'
                  YE: Yemen
                  ZM: Zambia
                  ZW: Zimbabwe
                properties:
                  AF:
                    type: string
                    example: Afghanistan
                  AX:
                    type: string
                    example: 'Aland Islands'
                  AL:
                    type: string
                    example: Albania
                  DZ:
                    type: string
                    example: Algeria
                  AS:
                    type: string
                    example: 'American Samoa'
                  AD:
                    type: string
                    example: Andorra
                  AO:
                    type: string
                    example: Angola
                  AI:
                    type: string
                    example: Anguilla
                  AQ:
                    type: string
                    example: Antarctica
                  AG:
                    type: string
                    example: 'Antigua and Barbuda'
                  AR:
                    type: string
                    example: Argentina
                  AM:
                    type: string
                    example: Armenia
                  AW:
                    type: string
                    example: Aruba
                  AU:
                    type: string
                    example: Australia
                  AT:
                    type: string
                    example: Austria
                  AZ:
                    type: string
                    example: Azerbaijan
                  BS:
                    type: string
                    example: Bahamas
                  BH:
                    type: string
                    example: Bahrain
                  BD:
                    type: string
                    example: Bangladesh
                  BB:
                    type: string
                    example: Barbados
                  BY:
                    type: string
                    example: Belarus
                  BE:
                    type: string
                    example: Belgium
                  BZ:
                    type: string
                    example: Belize
                  BJ:
                    type: string
                    example: Benin
                  BM:
                    type: string
                    example: Bermuda
                  BT:
                    type: string
                    example: Bhutan
                  BO:
                    type: string
                    example: Bolivia
                  BA:
                    type: string
                    example: 'Bosnia and Herzegovina'
                  BW:
                    type: string
                    example: Botswana
                  BV:
                    type: string
                    example: 'Bouvet Island'
                  BR:
                    type: string
                    example: Brazil
                  VG:
                    type: string
                    example: 'Virgin Islands, British'
                  BN:
                    type: string
                    example: Brunei
                  BG:
                    type: string
                    example: Bulgaria
                  BF:
                    type: string
                    example: 'Burkina Faso'
                  BI:
                    type: string
                    example: Burundi
                  KH:
                    type: string
                    example: Cambodia
                  CM:
                    type: string
                    example: Cameroon
                  CA:
                    type: string
                    example: Canada
                  CV:
                    type: string
                    example: 'Cape Verde'
                  KY:
                    type: string
                    example: 'Cayman Islands'
                  CF:
                    type: string
                    example: 'Central African Republic'
                  TD:
                    type: string
                    example: Chad
                  CL:
                    type: string
                    example: Chile
                  CN:
                    type: string
                    example: China
                  CX:
                    type: string
                    example: 'Christmas Island'
                  CC:
                    type: string
                    example: 'Cocos (Keeling) Islands'
                  CO:
                    type: string
                    example: Colombia
                  KM:
                    type: string
                    example: Comoros
                  CG:
                    type: string
                    example: Congo
                  CD:
                    type: string
                    example: 'Congo, The Democratic Republic of the'
                  CK:
                    type: string
                    example: 'Cook Islands'
                  CR:
                    type: string
                    example: 'Costa Rica'
                  CI:
                    type: string
                    example: "Cote d'Ivoire"
                  HR:
                    type: string
                    example: Croatia
                  CU:
                    type: string
                    example: Cuba
                  CW:
                    type: string
                    example: Curacao
                  CY:
                    type: string
                    example: Cyprus
                  CZ:
                    type: string
                    example: 'Czech Republic'
                  DK:
                    type: string
                    example: Denmark
                  DJ:
                    type: string
                    example: Djibouti
                  DM:
                    type: string
                    example: Dominica
                  DO:
                    type: string
                    example: 'Dominican Republic'
                  EC:
                    type: string
                    example: Ecuador
                  EG:
                    type: string
                    example: Egypt
                  SV:
                    type: string
                    example: 'El Salvador'
                  GQ:
                    type: string
                    example: 'Equatorial Guinea'
                  ER:
                    type: string
                    example: Eritrea
                  EE:
                    type: string
                    example: Estonia
                  ET:
                    type: string
                    example: Ethiopia
                  FK:
                    type: string
                    example: 'Falkland Islands (Malvinas)'
                  FO:
                    type: string
                    example: 'Faroe Islands'
                  FJ:
                    type: string
                    example: Fiji
                  FI:
                    type: string
                    example: Finland
                  FR:
                    type: string
                    example: France
                  GF:
                    type: string
                    example: 'French Guiana'
                  PF:
                    type: string
                    example: 'French Polynesia'
                  TF:
                    type: string
                    example: 'French Southern Territories'
                  GA:
                    type: string
                    example: Gabon
                  GM:
                    type: string
                    example: Gambia
                  GE:
                    type: string
                    example: Georgia
                  DE:
                    type: string
                    example: Germany
                  GH:
                    type: string
                    example: Ghana
                  GI:
                    type: string
                    example: Gibraltar
                  GR:
                    type: string
                    example: Greece
                  GL:
                    type: string
                    example: Greenland
                  GD:
                    type: string
                    example: Grenada
                  GP:
                    type: string
                    example: Guadeloupe
                  GU:
                    type: string
                    example: Guam
                  GT:
                    type: string
                    example: Guatemala
                  GG:
                    type: string
                    example: Guernsey
                  GN:
                    type: string
                    example: Guinea
                  GW:
                    type: string
                    example: Guinea-Bissau
                  GY:
                    type: string
                    example: Guyana
                  HT:
                    type: string
                    example: Haiti
                  HM:
                    type: string
                    example: 'Heard Island and McDonald Islands'
                  VA:
                    type: string
                    example: 'Holy See (Vatican City)'
                  HN:
                    type: string
                    example: Honduras
                  HK:
                    type: string
                    example: 'Hong Kong'
                  HU:
                    type: string
                    example: Hungary
                  IS:
                    type: string
                    example: Iceland
                  IN:
                    type: string
                    example: India
                  ID:
                    type: string
                    example: Indonesia
                  IR:
                    type: string
                    example: 'Iran, Islamic Republic of'
                  IQ:
                    type: string
                    example: Iraq
                  IE:
                    type: string
                    example: Ireland
                  IM:
                    type: string
                    example: 'Isle of Man'
                  IL:
                    type: string
                    example: Israel
                  IT:
                    type: string
                    example: Italy
                  JM:
                    type: string
                    example: Jamaica
                  JP:
                    type: string
                    example: Japan
                  JE:
                    type: string
                    example: Jersey
                  JO:
                    type: string
                    example: Jordan
                  KZ:
                    type: string
                    example: Kazakhstan
                  KE:
                    type: string
                    example: Kenya
                  KI:
                    type: string
                    example: Kiribati
                  KP:
                    type: string
                    example: "Korea, Democratic People's Republic of"
                  KR:
                    type: string
                    example: 'Korea, Republic of'
                  KW:
                    type: string
                    example: Kuwait
                  KG:
                    type: string
                    example: Kyrgyzstan
                  LA:
                    type: string
                    example: "Lao People's Democratic Republic"
                  LV:
                    type: string
                    example: Latvia
                  LB:
                    type: string
                    example: Lebanon
                  LS:
                    type: string
                    example: Lesotho
                  LR:
                    type: string
                    example: Liberia
                  LY:
                    type: string
                    example: 'Libyan Arab Jamahiriya'
                  LT:
                    type: string
                    example: Lithuania
                  LU:
                    type: string
                    example: Luxembourg
                  MO:
                    type: string
                    example: Macao
                  MK:
                    type: string
                    example: 'Macedonia, The Former Yugoslav Republic of'
                  MG:
                    type: string
                    example: Madagascar
                  MW:
                    type: string
                    example: Malawi
                  MY:
                    type: string
                    example: Malaysia
                  MV:
                    type: string
                    example: Maldives
                  ML:
                    type: string
                    example: Mali
                  MT:
                    type: string
                    example: Malta
                  MH:
                    type: string
                    example: 'Marshall Islands'
                  MQ:
                    type: string
                    example: Martinique
                  MR:
                    type: string
                    example: Mauritania
                  MU:
                    type: string
                    example: Mauritius
                  YT:
                    type: string
                    example: Mayotte
                  MX:
                    type: string
                    example: Mexico
                  FM:
                    type: string
                    example: 'Micronesia, Federated States of'
                  MD:
                    type: string
                    example: 'Moldova, Republic of'
                  MC:
                    type: string
                    example: Monaco
                  MN:
                    type: string
                    example: Mongolia
                  ME:
                    type: string
                    example: Montenegro
                  MS:
                    type: string
                    example: Montserrat
                  MA:
                    type: string
                    example: Morocco
                  MZ:
                    type: string
                    example: Mozambique
                  MM:
                    type: string
                    example: Myanmar
                  NA:
                    type: string
                    example: Namibia
                  NR:
                    type: string
                    example: Nauru
                  NP:
                    type: string
                    example: Nepal
                  NL:
                    type: string
                    example: Netherlands
                  NC:
                    type: string
                    example: 'New Caledonia'
                  NZ:
                    type: string
                    example: 'New Zealand'
                  NI:
                    type: string
                    example: Nicaragua
                  NE:
                    type: string
                    example: Niger
                  NG:
                    type: string
                    example: Nigeria
                  NU:
                    type: string
                    example: Niue
                  NF:
                    type: string
                    example: 'Norfolk Island'
                  MP:
                    type: string
                    example: 'Northern Mariana Islands'
                  'NO':
                    type: string
                    example: Norway
                  OM:
                    type: string
                    example: Oman
                  PK:
                    type: string
                    example: Pakistan
                  PW:
                    type: string
                    example: Palau
                  PS:
                    type: string
                    example: 'Palestinian Territory, Occupied'
                  PA:
                    type: string
                    example: Panama
                  PG:
                    type: string
                    example: 'Papua New Guinea'
                  PY:
                    type: string
                    example: Paraguay
                  PE:
                    type: string
                    example: Peru
                  PH:
                    type: string
                    example: Philippines
                  PN:
                    type: string
                    example: Pitcairn
                  PL:
                    type: string
                    example: Poland
                  PT:
                    type: string
                    example: Portugal
                  PR:
                    type: string
                    example: 'Puerto Rico'
                  QA:
                    type: string
                    example: Qatar
                  RE:
                    type: string
                    example: Reunion
                  RO:
                    type: string
                    example: Romania
                  RU:
                    type: string
                    example: 'Russian Federation'
                  RW:
                    type: string
                    example: Rwanda
                  BL:
                    type: string
                    example: 'Saint Barthelemy'
                  SH:
                    type: string
                    example: 'Saint Helena, Ascension and Tristan da Cunha'
                  KN:
                    type: string
                    example: 'Saint Kitts and Nevis'
                  LC:
                    type: string
                    example: 'Saint Lucia'
                  MF:
                    type: string
                    example: 'Saint Martin (French part)'
                  PM:
                    type: string
                    example: 'Saint Pierre and Miquelon'
                  VC:
                    type: string
                    example: 'Saint Vincent and the Grenadines'
                  WS:
                    type: string
                    example: Samoa
                  SM:
                    type: string
                    example: 'San Marino'
                  ST:
                    type: string
                    example: 'Sao Tome and Principe'
                  SA:
                    type: string
                    example: 'Saudi Arabia'
                  SN:
                    type: string
                    example: Senegal
                  RS:
                    type: string
                    example: Serbia
                  SC:
                    type: string
                    example: Seychelles
                  SL:
                    type: string
                    example: 'Sierra Leone'
                  SG:
                    type: string
                    example: Singapore
                  SX:
                    type: string
                    example: 'Sint Maarten (Dutch part)'
                  SK:
                    type: string
                    example: Slovakia
                  SI:
                    type: string
                    example: Slovenia
                  SB:
                    type: string
                    example: 'Solomon Islands'
                  SO:
                    type: string
                    example: Somalia
                  ZA:
                    type: string
                    example: 'South Africa'
                  GS:
                    type: string
                    example: 'South Georgia and the South Sandwich Islands'
                  SS:
                    type: string
                    example: 'South Sudan'
                  ES:
                    type: string
                    example: Spain
                  LK:
                    type: string
                    example: 'Sri Lanka'
                  SD:
                    type: string
                    example: Sudan
                  SR:
                    type: string
                    example: Suriname
                  SJ:
                    type: string
                    example: 'Svalbard and Jan Mayen'
                  SZ:
                    type: string
                    example: Swaziland
                  SE:
                    type: string
                    example: Sweden
                  CH:
                    type: string
                    example: Switzerland
                  SY:
                    type: string
                    example: 'Syrian Arab Republic'
                  TW:
                    type: string
                    example: 'Taiwan, Province of China'
                  TJ:
                    type: string
                    example: Tajikistan
                  TZ:
                    type: string
                    example: 'Tanzania, United Republic of'
                  TH:
                    type: string
                    example: Thailand
                  TL:
                    type: string
                    example: Timor-Leste
                  TG:
                    type: string
                    example: Togo
                  TK:
                    type: string
                    example: Tokelau
                  TO:
                    type: string
                    example: Tonga
                  TT:
                    type: string
                    example: 'Trinidad and Tobago'
                  TN:
                    type: string
                    example: Tunisia
                  TR:
                    type: string
                    example: Turkey
                  TM:
                    type: string
                    example: Turkmenistan
                  TC:
                    type: string
                    example: 'Turks and Caicos Islands'
                  TV:
                    type: string
                    example: Tuvalu
                  UG:
                    type: string
                    example: Uganda
                  UA:
                    type: string
                    example: Ukraine
                  AE:
                    type: string
                    example: 'United Arab Emirates'
                  GB:
                    type: string
                    example: 'United Kingdom'
                  US:
                    type: string
                    example: 'United States'
                  UM:
                    type: string
                    example: 'United States Minor Outlying Islands'
                  UY:
                    type: string
                    example: Uruguay
                  UZ:
                    type: string
                    example: Uzbekistan
                  VU:
                    type: string
                    example: Vanuatu
                  VE:
                    type: string
                    example: 'Venezuela, Bolivarian Republic of'
                  VN:
                    type: string
                    example: 'Viet Nam'
                  VI:
                    type: string
                    example: 'Virgin Islands, U.S.'
                  WF:
                    type: string
                    example: 'Wallis and Futuna'
                  EH:
                    type: string
                    example: 'Western Sahara'
                  YE:
                    type: string
                    example: Yemen
                  ZM:
                    type: string
                    example: Zambia
                  ZW:
                    type: string
                    example: Zimbabwe
      tags:
        - ECommerce
      security: []
  /api/states/lookup:
    get:
      summary: 'States Lookup'
      operationId: statesLookup
      description: "Retrieves all the states for a given country code in list format.\nHelps while showing states in form elements like dropdown."
      parameters:
        -
          in: query
          name: countryCode
          description: 'The country code for which the states are needed.'
          example: IN
          required: true
          schema:
            type: string
            description: 'The country code for which the states are needed.'
            example: IN
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: '{"KA":"Karnataka","KL":"Kerala","TN":"Tamil Nadu",...}'
      tags:
        - ECommerce
      security: []
  /api/currency/lookup:
    get:
      summary: 'Retrieves all the currencies.'
      operationId: retrievesAllTheCurrencies
      description: 'Fetches the list of all the currencies supported by the platform.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: '{"USD":"United States (US) dollar","EUR":"Euro","INR":"Indian rupee",...}'
      tags:
        - ECommerce
      security: []
  /api/settings/ecommerce/general:
    get:
      summary: 'Retrieves the general ecommerce settings. Helps in fetching items of the ecommerce settings, like country, city, address, location, etc(See Response)'
      operationId: retrievesTheGeneralEcommerceSettingsHelpsInFetchingItemsOfTheEcommerceSettingsLikeCountryCityAddressLocationEtcSeeResponse
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n     \"addressLine1\": \"1234 Lorem Ipsum Drive\",\n     \"addressLine2\": \"omnis\",\n     \"city\": \"New Jersey\",\n     \"state\": \"vel\",\n     \"country\": \"country\",\n     \"zipcode\": \"08053\",\n     \"selling_location\": \"all_countries\",\n     \"some_countries_excluded\": [],\n     \"some_countries\": [],\n     \"enableTaxes\": true,\n     \"enableCoupons\": true,\n     \"currency\": \"USD\",\n     \"productionMode\": true,\n     \"enableSaleTax\": true,\n     \"enableShipping\": true,\n}"
      tags:
        - ECommerce
      security: []
    put:
      summary: 'Set General Ecommerce Settings'
      operationId: setGeneralEcommerceSettings
      description: 'To save the general ecommerce settings with updated values, you need to use this request. (See parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                addressLine1:
                  type: string
                  description: 'Address Line 1 of shop.'
                  example: '1234 Lorem Ipsum Drive'
                addressLine2:
                  type: string
                  description: 'Address Line 2 of shop.'
                  example: omnis
                city:
                  type: string
                  description: 'City of shop.'
                  example: 'New Jersey'
                state:
                  type: string
                  description: 'State of shop.'
                  example: vel
                country:
                  type: string
                  description: 'Country of shop.'
                  example: country
                zipcode:
                  type: string
                  description: 'Zipcode of shop.'
                  example: '08053'
                enableCoupons:
                  type: boolean
                  description: 'If true, coupons are enabled.'
                  example: true
                currency:
                  type: string
                  description: 'Currency of shop.'
                  example: USD
              required:
                - addressLine1
                - addressLine2
                - city
                - state
                - country
                - zipcode
                - enableCoupons
                - currency
      security: []
  /api/settings/ecommerce/invoice:
    get:
      summary: 'Retrieves the invoice settings. Helps in fetching items of the invoice settings, like invoice business name, business name, tax settings, business info, etc(See Response)'
      operationId: retrievesTheInvoiceSettingsHelpsInFetchingItemsOfTheInvoiceSettingsLikeInvoiceBusinessNameBusinessNameTaxSettingsBusinessInfoEtcSeeResponse
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n     \"invoiceBusinessName\": \"defaultBusinessName\",\n     \"businessName\": \"Business Name\",\n     \"taxSettings\": \"inclusive\",\n     \"businessInfo\": {\n         \"addressLine1\": \"1234 Lorem Ipsum Drive\",\n         \"addressLine2\": \"omnis\",\n         \"city\": \"New Jersey\",\n         \"state\": \"vel\",\n         \"country\": \"country\",\n         \"zipcode\": \"08053\",\n     },\n}"
      tags:
        - ECommerce
      security: []
    put:
      summary: 'Set Invoice Settings'
      operationId: setInvoiceSettings
      description: 'Updates the settings for Invoice. Setting needs to be updated is mentioned in parameter. (See Parameter)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Order Invoice Settings Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Order Invoice Settings Updated Successfully'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                invoiceBusinessName:
                  type: string
                  description: 'Whether to use default business name or a custom business name.'
                  example: customBusinessName
                businessName:
                  type: string
                  description: 'required_if:invoiceBusinessName,customBusinessName Business name to be used in the invoice.'
                  example: 'Business Name'
                taxSettings:
                  type: string
                  description: 'Tax settings of the invoice.'
                  example: inclusive
              required:
                - invoiceBusinessName
      security: []
  /api/cartAbandonmentDetails:
    get:
      summary: 'Retrieve Cart Abandonment Details'
      operationId: retrieveCartAbandonmentDetails
      description: 'Fetches the cart abandonment details, including the cart total, status, abandoned at date, completed at date and products in the cart.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recoverableOrders: 0
                  recoveredOrders: 0
                  recoverableRevenue: '0.00'
                  recoveredRevenue: '0.00'
                  currency: USD
                  enableTracking: true
                  records:
                    -
                      id: 1
                      firstName: John
                      lastName: Doe
                      email: john@example.com
                      cartTotal: '100.00'
                      cartTotalNumber: 100
                      status: Abandoned
                      abandonedAt: '2022-01-01 12:00:00'
                      completedAt: null
                      orderId: null
                      products:
                        - 'Product 1'
                        - 'Product 2'
                properties:
                  recoverableOrders:
                    type: integer
                    example: 0
                  recoveredOrders:
                    type: integer
                    example: 0
                  recoverableRevenue:
                    type: string
                    example: '0.00'
                  recoveredRevenue:
                    type: string
                    example: '0.00'
                  currency:
                    type: string
                    example: USD
                  enableTracking:
                    type: boolean
                    example: true
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        firstName: John
                        lastName: Doe
                        email: john@example.com
                        cartTotal: '100.00'
                        cartTotalNumber: 100
                        status: Abandoned
                        abandonedAt: '2022-01-01 12:00:00'
                        completedAt: null
                        orderId: null
                        products:
                          - 'Product 1'
                          - 'Product 2'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        firstName:
                          type: string
                          example: John
                        lastName:
                          type: string
                          example: Doe
                        email:
                          type: string
                          example: john@example.com
                        cartTotal:
                          type: string
                          example: '100.00'
                        cartTotalNumber:
                          type: integer
                          example: 100
                        status:
                          type: string
                          example: Abandoned
                        abandonedAt:
                          type: string
                          example: '2022-01-01 12:00:00'
                        completedAt:
                          type: string
                          example: null
                        orderId:
                          type: string
                          example: null
                        products:
                          type: array
                          example:
                            - 'Product 1'
                            - 'Product 2'
                          items:
                            type: string
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                search_param:
                  type: object
                  description: 'The search parameters, including the abandoned at date range, status and name or email.'
                  example: []
                  properties:
                    abandonedAt:
                      type: array
                      description: 'The abandoned at date range.'
                      example:
                        - provident
                      items:
                        type: string
                    status:
                      type: array
                      description: 'The status of the cart abandonment.'
                      example:
                        - veritatis
                      items:
                        type: string
                    nameOrEmail:
                      type: string
                      description: 'The name or email of the user.'
                      example: bernita87@example.net
              required:
                - search_param
      security: []
  /api/get-shop-base-currency:
    get:
      summary: 'Retrieves the base currency of the shop.'
      operationId: retrievesTheBaseCurrencyOfTheShop
      description: 'Fetches the base currency set in the Ecommerce settings.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  currency: USD
                properties:
                  currency:
                    type: string
                    example: USD
      tags:
        - ECommerce
      security: []
  /api/settings/taxClasses/tabularlist:
    get:
      summary: 'Returns a list of all tax classes and their associated tax rates.'
      operationId: returnsAListOfAllTaxClassesAndTheirAssociatedTaxRates
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: Standard
                    description: 'Default tax class for general products'
                    showDetails: true
                    taxRates:
                      -
                        taxClassId: 1
                        rate_id: 101
                        name: 'US Standard Rate'
                        country: US
                        state:
                          - CA
                          - NY
                        zipCode:
                          - '90001'
                          - '10001'
                        rate: 7.25
                      -
                        taxClassId: 1
                        rate_id: 102
                        name: 'US Reduced Rate'
                        country: US
                        state:
                          - TX
                        zipCode:
                          - '73301'
                        rate: 6.5
      tags:
        - ECommerce
      security: []
  /api/settings/salesTax:
    post:
      summary: 'Creates a sales tax configuration.'
      operationId: createsASalesTaxConfiguration
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n     \"message\": \"Sales tax created successfully\",\n}"
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                pricesIncludeTax:
                  type: boolean
                  description: 'Whether prices include tax.'
                  example: true
                taxCalculationBasedOn:
                  type: string
                  description: 'Whether to calculate tax based on shipping or billing.'
                  example: '"shipping"'
                shippingTaxClass:
                  type: integer
                  description: 'The tax class for shipping.'
                  example: 1
                taxDisplaySuffix:
                  type: string
                  description: 'The suffix to display after tax.'
                  example: '"Incl. Tax"'
                displayTaxTotals:
                  type: boolean
                  description: 'Whether to display tax totals.'
                  example: true
              required:
                - pricesIncludeTax
                - taxCalculationBasedOn
                - shippingTaxClass
                - taxDisplaySuffix
                - displayTaxTotals
      security: []
  /api/settings/getSalesTax:
    get:
      summary: 'Retrieves the sales tax settings.'
      operationId: retrievesTheSalesTaxSettings
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  pricesIncludeTax: true
                  taxCalculationBasedOn: shipping
                  shippingTaxClass: 1
                  taxDisplaySuffix: 'Incl. Tax'
                  displayTaxTotals: true
                properties:
                  pricesIncludeTax:
                    type: boolean
                    example: true
                  taxCalculationBasedOn:
                    type: string
                    example: shipping
                  shippingTaxClass:
                    type: integer
                    example: 1
                  taxDisplaySuffix:
                    type: string
                    example: 'Incl. Tax'
                  displayTaxTotals:
                    type: boolean
                    example: true
      tags:
        - ECommerce
      security: []
  '/api/settings/taxClass/update/{id}':
    put:
      summary: 'Update a tax class.'
      operationId: updateATaxClass
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n     \"message\": \"Tax Class updated successfully\",\n}"
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'The name of the tax class.'
                  example: '"Sales Tax"'
                description:
                  type: string
                  description: 'The description of the tax class.'
                  example: '"This is a sales tax"'
              required:
                - name
                - description
      security: []
  /api/settings/taxClasses/delete:
    post:
      summary: 'Deletes a tax class and its associated tax rates.'
      operationId: deletesATaxClassAndItsAssociatedTaxRates
      description: "If a tax class is associated with a product, it will not be deleted.\n\nIf a tax class is associated with an order, it will not be deleted.\n\nIf a tax class is associated with an order item, it will not be deleted."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  deletedTaxClasses:
                    - 1
                    - 3
                  notDeletedTaxClasses:
                    -
                      order_id: 5001
                      tax_rate_id: 102
                      tax_rate_name: 'US Reduced Rate'
                    -
                      order_id: 5002
                      tax_rate_id: 201
                      tax_rate_name: 'EU Reduced Rate'
                  notDeletedTaxClassesProduct:
                    -
                      product_id: 3001
                      product_name: 'Wireless Mouse'
                      tax_class_id: 2
                    -
                      product_id: 3002
                      product_name: 'E-book Subscription'
                      tax_class_id: 2
                properties:
                  deletedTaxClasses:
                    type: array
                    example:
                      - 1
                      - 3
                    items:
                      type: integer
                  notDeletedTaxClasses:
                    type: array
                    example:
                      -
                        order_id: 5001
                        tax_rate_id: 102
                        tax_rate_name: 'US Reduced Rate'
                      -
                        order_id: 5002
                        tax_rate_id: 201
                        tax_rate_name: 'EU Reduced Rate'
                    items:
                      type: object
                      properties:
                        order_id:
                          type: integer
                          example: 5001
                        tax_rate_id:
                          type: integer
                          example: 102
                        tax_rate_name:
                          type: string
                          example: 'US Reduced Rate'
                  notDeletedTaxClassesProduct:
                    type: array
                    example:
                      -
                        product_id: 3001
                        product_name: 'Wireless Mouse'
                        tax_class_id: 2
                      -
                        product_id: 3002
                        product_name: 'E-book Subscription'
                        tax_class_id: 2
                    items:
                      type: object
                      properties:
                        product_id:
                          type: integer
                          example: 3001
                        product_name:
                          type: string
                          example: 'Wireless Mouse'
                        tax_class_id:
                          type: integer
                          example: 2
      tags:
        - ECommerce
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: array
                  description: 'of integers required The ids of the tax classes to delete.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
      security: []
  '/api/settings/taxRate/update/{id}':
    put:
      summary: 'Update a tax rate.'
      operationId: updateATaxRate
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n     \"message\": \"Tax rates updated successfully!\",\n}"
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                tax_class_id:
                  type: integer
                  description: 'optional The id of the tax class the tax rate belongs to.'
                  example: 1
                name:
                  type: string
                  description: 'The name of the tax rate.'
                  example: '"Sales Tax"'
                country:
                  type: string
                  description: 'The country of the tax rate.'
                  example: '"United States"'
                state:
                  type: string
                  description: 'optional The state of the tax rate.'
                  example: '"California"'
                zipCode:
                  type: array
                  description: 'of strings optional The zip codes of the tax rate.'
                  example:
                    - '10001'
                    - '10002'
                    - '10003'
                  items:
                    type: string
                rate:
                  type: number
                  description: 'optional The rate of the tax rate.'
                  example: 0.2
                appliedRateOn:
                  type: string
                  description: 'optional The rate on which the tax rate is applied.'
                  example: '"all_states"'
              required:
                - name
                - country
      security: []
  /api/settings/enablesalesTax:
    get:
      summary: 'Retrieves the sales tax settings.'
      operationId: retrievesTheSalesTaxSettings
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n     \"enableSalesTaxes\": true,\n}"
      tags:
        - ECommerce
      security: []
    put:
      summary: 'Updates the sales tax setting.'
      operationId: updatesTheSalesTaxSetting
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                  type: success
                  title: Success
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
                  type:
                    type: string
                    example: success
                  title:
                    type: string
                    example: Success
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enableSalesTaxes:
                  type: boolean
                  description: 'Whether to enable sales tax.'
                  example: true
              required:
                - enableSalesTaxes
      security: []
  /api/settings/taxClasses/create:
    post:
      summary: 'Creates a new tax class and associated tax rates.'
      operationId: createsANewTaxClassAndAssociatedTaxRates
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  success: true
                  message: 'Tax Class and Rates created successfully.'
                  tax_class_id: 1
                properties:
                  success:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Tax Class and Rates created successfully.'
                  tax_class_id:
                    type: integer
                    example: 1
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'The name of the tax class.'
                  example: '"Sales Tax"'
                description:
                  type: string
                  description: 'optional The description of the tax class.'
                  example: '"Sales tax"'
                taxRates:
                  type: array
                  description: 'of objects required The tax rates associated with the tax class.'
                  example:
                    -
                      name: 'Sales Tax'
                      country: 'United States'
                      state: California
                      zipCode:
                        - '10001'
                        - '10002'
                        - '10003'
                      rate: 0.2
                      appliedRateON: specific_states
                  items:
                    type: string
              required:
                - name
      security: []
  /api/settings/taxRate/delete:
    post:
      summary: 'Delete a tax rate.'
      operationId: deleteATaxRate
      description: 'If a tax rate is associated with any order, it will not be deleted and the API will return a list of orders which use the tax rate.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: failed
                  message: 'Tax rate could not be deleted as it is associated with existing orders.'
                  notDeletedTaxRates:
                    -
                      order_id: 4501
                      tax_rate_id: 1
                      tax_rate_name: 'US Standard Rate'
                    -
                      order_id: 4502
                      tax_rate_id: 1
                      tax_rate_name: 'US Standard Rate'
                properties:
                  status:
                    type: string
                    example: failed
                  message:
                    type: string
                    example: 'Tax rate could not be deleted as it is associated with existing orders.'
                  notDeletedTaxRates:
                    type: array
                    example:
                      -
                        order_id: 4501
                        tax_rate_id: 1
                        tax_rate_name: 'US Standard Rate'
                      -
                        order_id: 4502
                        tax_rate_id: 1
                        tax_rate_name: 'US Standard Rate'
                    items:
                      type: object
                      properties:
                        order_id:
                          type: integer
                          example: 4501
                        tax_rate_id:
                          type: integer
                          example: 1
                        tax_rate_name:
                          type: string
                          example: 'US Standard Rate'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_id:
                  type: integer
                  description: 'The ID of the tax rate to delete.'
                  example: 1
              required:
                - delete_id
      security: []
  '/api/settings/getTaxClass/{id}':
    get:
      summary: 'Loads a tax class by its ID.'
      operationId: loadsATaxClassByItsID
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: Standard
                  description: 'Default tax class for general products'
                  taxRates:
                    -
                      id: 101
                      name: 'US Standard Rate'
                      country: US
                      state:
                        - CA
                        - NY
                      zipCode:
                        - '90001'
                        - '10001'
                      rate: 7.25
                      appliedRateON: '2025-01-01T00:00:00Z'
                    -
                      id: 102
                      name: 'US Reduced Rate'
                      country: US
                      state:
                        - TX
                      zipCode:
                        - '73301'
                      rate: 6.5
                      appliedRateON: '2025-03-15T00:00:00Z'
                properties:
                  name:
                    type: string
                    example: Standard
                  description:
                    type: string
                    example: 'Default tax class for general products'
                  taxRates:
                    type: array
                    example:
                      -
                        id: 101
                        name: 'US Standard Rate'
                        country: US
                        state:
                          - CA
                          - NY
                        zipCode:
                          - '90001'
                          - '10001'
                        rate: 7.25
                        appliedRateON: '2025-01-01T00:00:00Z'
                      -
                        id: 102
                        name: 'US Reduced Rate'
                        country: US
                        state:
                          - TX
                        zipCode:
                          - '73301'
                        rate: 6.5
                        appliedRateON: '2025-03-15T00:00:00Z'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 101
                        name:
                          type: string
                          example: 'US Standard Rate'
                        country:
                          type: string
                          example: US
                        state:
                          type: array
                          example:
                            - CA
                            - NY
                          items:
                            type: string
                        zipCode:
                          type: array
                          example:
                            - '90001'
                            - '10001'
                          items:
                            type: string
                        rate:
                          type: number
                          example: 7.25
                        appliedRateON:
                          type: string
                          example: '2025-01-01T00:00:00Z'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The ID of the tax class.'
                  example: 1
              required:
                - id
      security: []
  /api/settings/taxRate/add:
    post:
      summary: 'Add a tax rate.'
      operationId: addATaxRate
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n     \"message\": \"Tax rate added successfully!\",\n}"
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                tax_class_id:
                  type: integer
                  description: 'The ID of the tax class.'
                  example: 1
                name:
                  type: string
                  description: 'The name of the tax rate.'
                  example: '"Sales Tax"'
                country:
                  type: string
                  description: 'The country of the tax rate.'
                  example: '"United States"'
                state:
                  type: array
                  description: 'of strings optional The state of the tax rate.'
                  example:
                    - California
                  items:
                    type: string
                zipCode:
                  type: array
                  description: 'of strings optional The zip codes of the tax rate.'
                  example:
                    - '10001'
                    - '10002'
                    - '10003'
                  items:
                    type: string
                rate:
                  type: number
                  description: 'The rate of the tax rate.'
                  example: 0.2
                appliedRateOn:
                  type: string
                  description: 'The rate on which the tax rate is applied.'
                  example: '"all_states"'
              required:
                - tax_class_id
                - name
                - country
                - rate
                - appliedRateOn
      security: []
  /api/settings/ecommerce/toggleShippingSettings:
    put:
      summary: 'Toggle Shipping Settings'
      operationId: toggleShippingSettings
      description: 'Updates the shipping settings to enable or disable shipping based on the provided request parameter.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                  type: success
                  title: Success
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
                  type:
                    type: string
                    example: success
                  title:
                    type: string
                    example: Success
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enableShipping:
                  type: boolean
                  description: 'Whether to enable or disable shipping.'
                  example: true
              required:
                - enableShipping
      security: []
  /api/settings/ecommerce/shipping:
    post:
      summary: 'Set Shipping Setting'
      operationId: setShippingSetting
      description: 'Updates the settings for shipping. Setting needs to be updated is mentioned in parameter. (See Parameter)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Sales Tax Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Sales Tax Updated Successfully'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                shippingDestination:
                  type: string
                  description: 'Shipping destination of order.'
                  example: billing_address
              required:
                - shippingDestination
      security: []
    get:
      summary: 'Retrieves the shipping settings.'
      operationId: retrievesTheShippingSettings
      description: 'Helps in fetching items of the shipping settings, like shipping destination and whether shipping is enabled or disabled.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  shippingDestination: '123 Main Street, Springfield, IL 62704, USA'
                  enableShipping: true
                properties:
                  shippingDestination:
                    type: string
                    example: '123 Main Street, Springfield, IL 62704, USA'
                  enableShipping:
                    type: boolean
                    example: true
      tags:
        - ECommerce
      security: []
  /api/settings/ecommerce/shipping-zones:
    get:
      summary: 'Get all shipping zones.'
      operationId: getAllShippingZones
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      name: 'Shipping Zone 1'
                      country: India
                      state:
                        - Delhi
                        - Punjab
                      zip_code:
                        - '110000'
                        - '110001'
                      shippingMethods: 'Flat Rate, Free Shipping'
                      shippingMethod:
                        'Flat Rate':
                          cost: 0.0
                          minAmountRequired: 0.0
                          taxStatus: Taxable
                        'Free Shipping':
                          cost: 0.0
                          minAmountRequired: 0.0
                          taxStatus: Taxable
                  currency: INR
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Shipping Zone 1'
                        country: India
                        state:
                          - Delhi
                          - Punjab
                        zip_code:
                          - '110000'
                          - '110001'
                        shippingMethods: 'Flat Rate, Free Shipping'
                        shippingMethod:
                          'Flat Rate':
                            cost: 0
                            minAmountRequired: 0
                            taxStatus: Taxable
                          'Free Shipping':
                            cost: 0
                            minAmountRequired: 0
                            taxStatus: Taxable
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Shipping Zone 1'
                        country:
                          type: string
                          example: India
                        state:
                          type: array
                          example:
                            - Delhi
                            - Punjab
                          items:
                            type: string
                        zip_code:
                          type: array
                          example:
                            - '110000'
                            - '110001'
                          items:
                            type: string
                        shippingMethods:
                          type: string
                          example: 'Flat Rate, Free Shipping'
                        shippingMethod:
                          type: object
                          properties:
                            'Flat Rate':
                              type: object
                              properties:
                                cost:
                                  type: number
                                  example: 0.0
                                minAmountRequired:
                                  type: number
                                  example: 0.0
                                taxStatus:
                                  type: string
                                  example: Taxable
                            'Free Shipping':
                              type: object
                              properties:
                                cost:
                                  type: number
                                  example: 0.0
                                minAmountRequired:
                                  type: number
                                  example: 0.0
                                taxStatus:
                                  type: string
                                  example: Taxable
                  currency:
                    type: string
                    example: INR
      tags:
        - ECommerce
      security: []
  '/api/settings/ecommerce/shipping-zones-methods/{id}':
    get:
      summary: 'Retrieve Shipping Zone Methods'
      operationId: retrieveShippingZoneMethods
      description: 'Fetches details of a specific shipping zone, including its name, country, state, zip code, applied zone criteria, and associated shipping methods.'
      parameters:
        -
          in: query
          name: id
          description: 'The ID of the shipping zone to retrieve.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The ID of the shipping zone to retrieve.'
            example: 1
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: California
                  country: US
                  state:
                    - CA
                  zip_code:
                    - '94000'
                    - '95000'
                  appliedZoneOn: specific_states
                  shippingMethods:
                    -
                      id: 1
                      name: 'Flat Rate Shipping'
                      isEnabled: true
                      shippingMethod: flat_rate
                      taxStatus: taxable
                      cost: '10.00'
                      minAmountRequired: true
                      minimumOrderAmount: 50
                properties:
                  name:
                    type: string
                    example: California
                  country:
                    type: string
                    example: US
                  state:
                    type: array
                    example:
                      - CA
                    items:
                      type: string
                  zip_code:
                    type: array
                    example:
                      - '94000'
                      - '95000'
                    items:
                      type: string
                  appliedZoneOn:
                    type: string
                    example: specific_states
                  shippingMethods:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Flat Rate Shipping'
                        isEnabled: true
                        shippingMethod: flat_rate
                        taxStatus: taxable
                        cost: '10.00'
                        minAmountRequired: true
                        minimumOrderAmount: 50
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Flat Rate Shipping'
                        isEnabled:
                          type: boolean
                          example: true
                        shippingMethod:
                          type: string
                          example: flat_rate
                        taxStatus:
                          type: string
                          example: taxable
                        cost:
                          type: string
                          example: '10.00'
                        minAmountRequired:
                          type: boolean
                          example: true
                        minimumOrderAmount:
                          type: integer
                          example: 50
      tags:
        - ECommerce
      security: []
  /api/settings/ecommerce/shipping-zone:
    post:
      summary: 'Creates a new shipping zone.'
      operationId: createsANewShippingZone
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  success: true
                  message: 'Shipping Zone Created Successfully'
                  shippingZoneId: 1
                properties:
                  success:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Shipping Zone Created Successfully'
                  shippingZoneId:
                    type: integer
                    example: 1
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'The name of the shipping zone.'
                  example: USA
                country:
                  type: string
                  description: 'The country to associate the shipping zone with.'
                  example: US
                appliedZoneOn:
                  type: string
                  description: 'The type of shipping zone.'
                  example: specific_states
                zip_code:
                  type: string
                  description: 'The zip code(s) to associate with the shipping zone.'
                  example: '5600556, 5658666, 8474841'
                state:
                  type: array
                  description: 'The state(s) to associate with the shipping zone.'
                  example:
                    - AL
                    - AK
                    - AZ
                    - AR
                    - CA
                  items:
                    type: string
                shippingMethod:
                  type: array
                  description: 'The shipping method details.'
                  example:
                    -
                      name: 'Flat Rate'
                      isEnabled: true
                      shippingMethod: flat_rate
                      taxStatus: taxable
                      cost: 10.99
                      minAmountRequired: 100.0
                      minimumOrderAmount: 150.0
                  items:
                    type: string
              required:
                - name
                - country
                - appliedZoneOn
                - zip_code
                - state
                - shippingMethod
      security: []
  '/api/settings/ecommerce/shipping-zone/{id}':
    put:
      summary: 'Updates a shipping zone.'
      operationId: updatesAShippingZone
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Shipping Zone Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Shipping Zone Updated Successfully'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The ID of the shipping zone.'
                  example: 1
                name:
                  type: string
                  description: 'The name of the shipping zone.'
                  example: 'US East Zone'
                country:
                  type: string
                  description: 'The country of the shipping zone.'
                  example: US
                appliedZoneOn:
                  type: string
                  description: "The application scope of the zone, either 'zip_code', 'specific_states', or 'all_states'."
                  example: zip_code
                zip_code:
                  type: string
                  description: 'optional Comma-separated zip codes if the zone applies to zip codes.'
                  example: '12345,67890'
                state:
                  type: array
                  description: 'optional States if the zone applies to specific states.'
                  example:
                    - NY
                    - NJ
                  items:
                    type: string
              required:
                - id
                - name
                - country
                - appliedZoneOn
      security: []
  '/api/settings/ecommerce/shipping-zone/delete/{id}':
    post:
      summary: 'Delete a shipping zone.'
      operationId: deleteAShippingZone
      description: 'If the shipping zone is associated with one or more shipping methods, the method is not deleted and the response contains a list of orders that prevents the deletion.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: true
                  message: 'Shipping Zone deleted successfully'
                  notDeletedShippingZone: []
                properties:
                  status:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Shipping Zone deleted successfully'
                  notDeletedShippingZone:
                    type: array
                    example: []
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The ID of the shipping method to delete.'
                  example: 1
              required:
                - id
      security: []
  '/api/settings/ecommerce/shipping-method/delete/{id}':
    post:
      summary: 'Delete a shipping method.'
      operationId: deleteAShippingMethod
      description: 'If the shipping method is associated with one or more orders, the method is not deleted and the response contains a list of orders that prevents the deletion.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  success: true
                  message: 'Shipping method deleted successfully'
                  notDeletedShippingMethod: []
                properties:
                  success:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Shipping method deleted successfully'
                  notDeletedShippingMethod:
                    type: array
                    example: []
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The ID of the shipping method to delete.'
                  example: 1
              required:
                - id
      security: []
  /api/settings/ecommerce/shipping-method/create:
    post:
      summary: 'Creates a new shipping method.'
      operationId: createsANewShippingMethod
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Shipping method added successfully!'
                properties:
                  message:
                    type: string
                    example: 'Shipping method added successfully!'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'The title of the shipping method.'
                  example: 'Flat Rate'
                shippingZoneId:
                  type: integer
                  description: 'The ID of the shipping zone to associate the method with.'
                  example: 1
                taxStatus:
                  type: string
                  description: 'The tax status of the shipping method.'
                  example: taxable
                cost:
                  type: number
                  description: 'The cost of the shipping method.'
                  example: 10.99
                isEnabled:
                  type: boolean
                  description: 'Whether the shipping method should be enabled.'
                  example: true
                shippingMethod:
                  type: string
                  description: 'The type of shipping method.'
                  example: 'Flat Rate'
                minAmountRequired:
                  type: number
                  description: 'The minimum amount required for free shipping.'
                  example: 100.0
                minimumOrderAmount:
                  type: number
                  description: 'The minimum amount required for free shipping.'
                  example: 100.0
              required:
                - name
                - shippingZoneId
                - taxStatus
                - cost
                - isEnabled
                - shippingMethod
                - minAmountRequired
                - minimumOrderAmount
      security: []
  '/api/settings/ecommerce/shipping-method/update/{id}':
    post:
      summary: 'Updates a shipping method.'
      operationId: updatesAShippingMethod
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Shipping method updated successfully!'
                properties:
                  message:
                    type: string
                    example: 'Shipping method updated successfully!'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'The title of the shipping method.'
                  example: 'Flat Rate'
                shippingZoneId:
                  type: integer
                  description: 'The ID of the shipping zone to associate the method with.'
                  example: 1
                taxStatus:
                  type: string
                  description: 'The tax status of the shipping method.'
                  example: taxable
                cost:
                  type: number
                  description: 'The cost of the shipping method.'
                  example: 10.99
                isEnabled:
                  type: boolean
                  description: 'Whether the shipping method should be enabled.'
                  example: true
                shippingMethod:
                  type: string
                  description: 'The type of shipping method.'
                  example: 'Flat Rate'
                minAmountRequired:
                  type: number
                  description: 'The minimum amount required for free shipping.'
                  example: 100.0
                minimumOrderAmount:
                  type: number
                  description: 'The minimum amount required for free shipping.'
                  example: 100.0
              required:
                - name
                - shippingZoneId
                - taxStatus
                - cost
                - isEnabled
                - shippingMethod
                - minAmountRequired
                - minimumOrderAmount
      security: []
  /api/settings/ecommerce/shipping-method/update-status:
    post:
      summary: 'Update the status of a shipping method.'
      operationId: updateTheStatusOfAShippingMethod
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Shipping method status updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Shipping method status updated successfully'
      tags:
        - ECommerce
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The ID of the shipping method to update.'
                  example: 1
                isEnabled:
                  type: boolean
                  description: 'Whether the shipping method should be enabled.'
                  example: true
              required:
                - id
                - isEnabled
      security: []
  /api/orders/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the orders in a tabular list format with pagination mode.\nYou can apply filter using search_param via status(order status), user(user email or id), dateRange(date range)."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the orders you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the orders you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'For searching items based on status, user, date range.'
          example: '{"status":["pending"],"user":["1"],"dateRange":["2020-01-01","2020-01-31"]}'
          required: false
          schema:
            type: string
            description: 'For searching items based on status, user, date range.'
            example: '{"status":["pending"],"user":["1"],"dateRange":["2020-01-01","2020-01-31"]}'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: 5
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      status: pending
                      display_status: Pending
                      total: '100.00'
                      isTestOrder: false
                      customer: 'John Doe'
                      email: john@example.com
                      created_at: 'Jan 01, 2020 12:00 AM'
                      isPortalOrder: false
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        status: pending
                        display_status: Pending
                        total: '100.00'
                        isTestOrder: false
                        customer: 'John Doe'
                        email: john@example.com
                        created_at: 'Jan 01, 2020 12:00 AM'
                        isPortalOrder: false
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        status:
                          type: string
                          example: pending
                        display_status:
                          type: string
                          example: Pending
                        total:
                          type: string
                          example: '100.00'
                        isTestOrder:
                          type: boolean
                          example: false
                        customer:
                          type: string
                          example: 'John Doe'
                        email:
                          type: string
                          example: john@example.com
                        created_at:
                          type: string
                          example: 'Jan 01, 2020 12:00 AM'
                        isPortalOrder:
                          type: boolean
                          example: false
      tags:
        - 'ECommerce Orders'
      security: []
  /api/order/download:
    get:
      summary: 'Download the PDF invoice for a specific order.'
      operationId: downloadThePDFInvoiceForASpecificOrder
      description: "This endpoint allows authorized users to download a PDF invoice for a given order.\n- General users can download only their own orders.\n- Admins, owners, and staff can download any order.\n\nThe invoice includes billing/shipping information, tax breakdowns, product details, and more."
      parameters:
        -
          in: query
          name: orderId
          description: 'The ID of the order to download the invoice for.'
          example: 1023
          required: true
          schema:
            type: integer
            description: 'The ID of the order to download the invoice for.'
            example: 1023
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Invoice downloaded successfully.'
                  file: /downloads/order.pdf
                properties:
                  message:
                    type: string
                    example: 'Invoice downloaded successfully.'
                  file:
                    type: string
                    example: /downloads/order.pdf
      tags:
        - 'ECommerce Orders'
      security: []
  /api/order/export:
    get:
      summary: 'Export Orders'
      operationId: exportOrders
      description: "Exports the order details based on the provided filters to an Excel file.\nThe filters can include various criteria such as date range, user, product, etc.\nThe generated file is downloaded as 'orders-test.xlsx'."
      parameters:
        -
          in: query
          name: filters
          description: 'JSON encoded filters to apply for exporting order details.'
          example: '{"dateRange":["2020-07-31","2020-08-30"],"users":[3],"products":[1]}'
          required: true
          schema:
            type: string
            description: 'JSON encoded filters to apply for exporting order details.'
            example: '{"dateRange":["2020-07-31","2020-08-30"],"users":[3],"products":[1]}'
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: 'A downloadable Excel file containing the filtered order details.'
      tags:
        - 'ECommerce Orders'
      security: []
  /api/order/reports/yearsales:
    get:
      summary: 'Retrieve Yearly Sales'
      operationId: retrieveYearlySales
      description: "Retrieves the details of yearly based order sales made from students and returns in tabular form.\nYou can use the response for plotting graphs"
      parameters:
        -
          in: query
          name: year
          description: 'Year for which you need sales information.'
          example: '2020'
          required: true
          schema:
            type: string
            description: 'Year for which you need sales information.'
            example: '2020'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  labels:
                    - Jan
                    - Feb
                    - Mar
                    - Apr
                    - May
                    - Jun
                    - Jul
                    - Aug
                    - Sep
                    - Oct
                    - Nov
                    - Dec
                  totalIncome:
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                  totalOrders:
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                  currency:
                    display_name: 'United States (US) dollar'
                    symbol: '&#36;'
                  sumIncome: 0
                  sumTotalOrder: 0
                properties:
                  labels:
                    type: array
                    example:
                      - Jan
                      - Feb
                      - Mar
                      - Apr
                      - May
                      - Jun
                      - Jul
                      - Aug
                      - Sep
                      - Oct
                      - Nov
                      - Dec
                    items:
                      type: string
                  totalIncome:
                    type: array
                    example:
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                    items:
                      type: integer
                  totalOrders:
                    type: array
                    example:
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                    items:
                      type: integer
                  currency:
                    type: object
                    properties:
                      display_name:
                        type: string
                        example: 'United States (US) dollar'
                      symbol:
                        type: string
                        example: '&#36;'
                  sumIncome:
                    type: integer
                    example: 0
                  sumTotalOrder:
                    type: integer
                    example: 0
      tags:
        - 'ECommerce Orders'
      security: []
  /api/order/reports/monthlysales:
    get:
      summary: 'Retrieves the details of order sales for this month made from students and returns in tabular form.'
      operationId: retrievesTheDetailsOfOrderSalesForThisMonthMadeFromStudentsAndReturnsInTabularForm
      description: 'You can use the response for plotting graphs'
      parameters:
        -
          in: query
          name: selectedMonth
          description: 'Month for which you need sales information(month_number-year).'
          example: 1-2020
          required: true
          schema:
            type: string
            description: 'Month for which you need sales information(month_number-year).'
            example: 1-2020
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  labels:
                    - Jan-01
                    - Jan-02
                    - Jan-03
                    - Jan-04
                    - Jan-05
                    - Jan-06
                    - Jan-07
                    - Jan-08
                    - Jan-09
                    - Jan-10
                    - Jan-11
                    - Jan-12
                  totalIncome:
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                  totalOrders:
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                    - 0
                  currency:
                    display_name: 'United States (US) dollar'
                    symbol: '&#36;'
                  sumIncome: 0
                  sumTotalOrder: 0
                properties:
                  labels:
                    type: array
                    example:
                      - Jan-01
                      - Jan-02
                      - Jan-03
                      - Jan-04
                      - Jan-05
                      - Jan-06
                      - Jan-07
                      - Jan-08
                      - Jan-09
                      - Jan-10
                      - Jan-11
                      - Jan-12
                    items:
                      type: string
                  totalIncome:
                    type: array
                    example:
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                    items:
                      type: integer
                  totalOrders:
                    type: array
                    example:
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                      - 0
                    items:
                      type: integer
                  currency:
                    type: object
                    properties:
                      display_name:
                        type: string
                        example: 'United States (US) dollar'
                      symbol:
                        type: string
                        example: '&#36;'
                  sumIncome:
                    type: integer
                    example: 0
                  sumTotalOrder:
                    type: integer
                    example: 0
      tags:
        - 'ECommerce Orders'
      security: []
  /api/order/reports/productbreakdown:
    get:
      summary: 'Retrieve Product Breakdown Sales'
      operationId: retrieveProductBreakdownSales
      description: "Retrieves the details of product break-down based order sales for a given date range made from students and returns in tabular form.\nYou can use the response for plotting graphs"
      parameters:
        -
          in: query
          name: selectedDateRange
          description: 'Date range for which you need sales information (start_date-end_date).'
          example: 2020-01-01-2020-01-31
          required: true
          schema:
            type: string
            description: 'Date range for which you need sales information (start_date-end_date).'
            example: 2020-01-01-2020-01-31
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  labels:
                    - Product-1
                    - Product-2
                  totalIncome:
                    - 0
                    - 0
                  totalOrders:
                    - 0
                    - 0
                  currency:
                    display_name: 'United States (US) dollar'
                    symbol: '&#36;'
                  sumIncome: 0
                  sumTotalOrder: 0
                properties:
                  labels:
                    type: array
                    example:
                      - Product-1
                      - Product-2
                    items:
                      type: string
                  totalIncome:
                    type: array
                    example:
                      - 0
                      - 0
                    items:
                      type: integer
                  totalOrders:
                    type: array
                    example:
                      - 0
                      - 0
                    items:
                      type: integer
                  currency:
                    type: object
                    properties:
                      display_name:
                        type: string
                        example: 'United States (US) dollar'
                      symbol:
                        type: string
                        example: '&#36;'
                  sumIncome:
                    type: integer
                    example: 0
                  sumTotalOrder:
                    type: integer
                    example: 0
      tags:
        - 'ECommerce Orders'
      security: []
  /api/order/status/lookup:
    get:
      summary: 'Order Status Lookup'
      operationId: orderStatusLookup
      description: "Retrieves all the possible statuses for an order, such as pending payment,\ncompleted, cancelled, refunded, failed, awaiting shipping, and shipped.\nThis is useful for showing options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: PENDING_PAYMENT
                    display_value: 'Payment Pending'
                  -
                    db_value: COMPLETED
                    display_value: Completed
                  -
                    db_value: CANCELLED
                    display_value: Cancelled
                  -
                    db_value: REFUNDED
                    display_value: Refunded
                  -
                    db_value: FAILED
                    display_value: Failed
                  -
                    db_value: AWAITING_SHIPPING
                    display_value: 'Awaiting Shipping'
                  -
                    db_value: SHIPPED
                    display_value: Shipped
      tags:
        - 'ECommerce Orders'
      security: []
  /api/order/delete:
    post:
      summary: 'Delete Order'
      operationId: deleteOrder
      description: 'Deletes one or more orders based on the ids provided in the request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '1 order(s) deleted.'
                properties:
                  message:
                    type: string
                    example: '1 order(s) deleted.'
        500:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Something went wrong'
                properties:
                  message:
                    type: string
                    example: 'Something went wrong'
      tags:
        - 'ECommerce Orders'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: required
                  description: 'The IDs of the orders to delete.'
                  example: '[1,2,3]'
      security: []
  /api/order/create:
    post:
      summary: 'Create Order'
      operationId: createOrder
      description: "Creates a new order. (See parameters)\nOrders can be used as purchasing products by students."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Order created successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Order created successfully'
      tags:
        - 'ECommerce Orders'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                orderDate:
                  type: date
                  description: 'Ordering date.'
                  example: '2020-08-25 0:00:00'
                status:
                  type: string
                  description: 'Different status for the orders like pending, completed, failed, etc. Status options: PENDING_PAYMENT, COMPLETED, CANCELLED, REFUNDED or FAILED.'
                  example: COMPLETED
                customerId:
                  type: integer
                  description: 'Ordered by this user Id.'
                  example: 3
                billingAddressId:
                  type: integer
                  description: 'Billing address Id.'
                  example: 3500
                shippingAddressId:
                  type: integer
                  description: 'Shipping address Id.'
                  example: 3500
                orderItems:
                  type: array
                  description: 'All added item for this order purchased together.'
                  example:
                    - qui
                  items:
                    type: string
                orderNotes:
                  type: array
                  description: 'Notes either public or private while creating course(to remeber something, like normal note).'
                  example:
                    - eum
                  items:
                    type: string
                taxAmount:
                  type: numeric
                  description: 'Tax amount.'
                  example: 'null'
                otherFee:
                  type: numeric
                  description: 'Other extra fees.'
                  example: 'null'
              required:
                - orderDate
                - status
                - customerId
                - orderItems
      security: []
  '/api/order/{id}':
    get:
      summary: 'Retrieves the details of a specified order.'
      operationId: retrievesTheDetailsOfASpecifiedOrder
      description: 'Helps in fetching order using its ID.'
      parameters:
        -
          in: query
          name: id
          description: 'Order Id.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Order Id.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  orderDate: '2022-11-16 14:19:45'
                  status: PENDING_PAYMENT
                  display_status: 'Pending Payment'
                  customerId: 1
                  billingAddressId: 1
                  shippingAddressId: 1
                  taxAmount: 0
                  otherFee: 0
                  isTestOrder: false
                  total: '10.00'
                  sub_total: '10.00'
                  currency: USD
                  shopAddress: '123 Main St, Anytown, CA 12345, USA'
                  billingAddress:
                    id: 1
                    first_name: John
                    last_name: Doe
                    company_name: 'Company Name'
                    street_address: '123 Main St'
                    apartment_suite_number: 'Apt 101'
                    city: Anytown
                    state: CA
                    zip: '12345'
                    country: US
                  shippingAddress:
                    id: 1
                    first_name: John
                    last_name: Doe
                    company_name: 'Company Name'
                    street_address: '123 Main St'
                    apartment_suite_number: 'Apt 101'
                    city: Anytown
                    state: CA
                    zip: '12345'
                    country: US
                  coupon_used: null
                  paymentGatewayId: 1
                  paymentGatewayEnabled: true
                  companyName: null
                  isShippingRequired: false
                  thankYouUrl: /thank-you
                  shippingMethodId: 1
                  shippingTax: 0
                  shippingTaxRateId: null
                  orderNotes: []
                  orderItems:
                    -
                      product_id: 1
                      product_title: 'Product Title'
                      price: '10.00'
                      quantity: 1
                      total: '10.00'
                      initialProductPrice: '10.00'
                      taxRateId: null
                      tax: 0
                      isShippingRequired: false
                      saleTax: 0
                  taxSettings:
                    enable_tax: true
                    tax_base: base_price
                    tax_rate: 0
                  taxRates:
                    -
                      taxRateId: 1
                      taxRateName: 'Tax Rate Name'
                      totalTax: '0.00'
                  totalTax: '0.00'
                properties:
                  id:
                    type: integer
                    example: 1
                  orderDate:
                    type: string
                    example: '2022-11-16 14:19:45'
                  status:
                    type: string
                    example: PENDING_PAYMENT
                  display_status:
                    type: string
                    example: 'Pending Payment'
                  customerId:
                    type: integer
                    example: 1
                  billingAddressId:
                    type: integer
                    example: 1
                  shippingAddressId:
                    type: integer
                    example: 1
                  taxAmount:
                    type: integer
                    example: 0
                  otherFee:
                    type: integer
                    example: 0
                  isTestOrder:
                    type: boolean
                    example: false
                  total:
                    type: string
                    example: '10.00'
                  sub_total:
                    type: string
                    example: '10.00'
                  currency:
                    type: string
                    example: USD
                  shopAddress:
                    type: string
                    example: '123 Main St, Anytown, CA 12345, USA'
                  billingAddress:
                    type: object
                    properties:
                      id:
                        type: integer
                        example: 1
                      first_name:
                        type: string
                        example: John
                      last_name:
                        type: string
                        example: Doe
                      company_name:
                        type: string
                        example: 'Company Name'
                      street_address:
                        type: string
                        example: '123 Main St'
                      apartment_suite_number:
                        type: string
                        example: 'Apt 101'
                      city:
                        type: string
                        example: Anytown
                      state:
                        type: string
                        example: CA
                      zip:
                        type: string
                        example: '12345'
                      country:
                        type: string
                        example: US
                  shippingAddress:
                    type: object
                    properties:
                      id:
                        type: integer
                        example: 1
                      first_name:
                        type: string
                        example: John
                      last_name:
                        type: string
                        example: Doe
                      company_name:
                        type: string
                        example: 'Company Name'
                      street_address:
                        type: string
                        example: '123 Main St'
                      apartment_suite_number:
                        type: string
                        example: 'Apt 101'
                      city:
                        type: string
                        example: Anytown
                      state:
                        type: string
                        example: CA
                      zip:
                        type: string
                        example: '12345'
                      country:
                        type: string
                        example: US
                  coupon_used:
                    type: string
                    example: null
                  paymentGatewayId:
                    type: integer
                    example: 1
                  paymentGatewayEnabled:
                    type: boolean
                    example: true
                  companyName:
                    type: string
                    example: null
                  isShippingRequired:
                    type: boolean
                    example: false
                  thankYouUrl:
                    type: string
                    example: /thank-you
                  shippingMethodId:
                    type: integer
                    example: 1
                  shippingTax:
                    type: integer
                    example: 0
                  shippingTaxRateId:
                    type: string
                    example: null
                  orderNotes:
                    type: array
                    example: []
                  orderItems:
                    type: array
                    example:
                      -
                        product_id: 1
                        product_title: 'Product Title'
                        price: '10.00'
                        quantity: 1
                        total: '10.00'
                        initialProductPrice: '10.00'
                        taxRateId: null
                        tax: 0
                        isShippingRequired: false
                        saleTax: 0
                    items:
                      type: object
                      properties:
                        product_id:
                          type: integer
                          example: 1
                        product_title:
                          type: string
                          example: 'Product Title'
                        price:
                          type: string
                          example: '10.00'
                        quantity:
                          type: integer
                          example: 1
                        total:
                          type: string
                          example: '10.00'
                        initialProductPrice:
                          type: string
                          example: '10.00'
                        taxRateId:
                          type: string
                          example: null
                        tax:
                          type: integer
                          example: 0
                        isShippingRequired:
                          type: boolean
                          example: false
                        saleTax:
                          type: integer
                          example: 0
                  taxSettings:
                    type: object
                    properties:
                      enable_tax:
                        type: boolean
                        example: true
                      tax_base:
                        type: string
                        example: base_price
                      tax_rate:
                        type: integer
                        example: 0
                  taxRates:
                    type: array
                    example:
                      -
                        taxRateId: 1
                        taxRateName: 'Tax Rate Name'
                        totalTax: '0.00'
                    items:
                      type: object
                      properties:
                        taxRateId:
                          type: integer
                          example: 1
                        taxRateName:
                          type: string
                          example: 'Tax Rate Name'
                        totalTax:
                          type: string
                          example: '0.00'
                  totalTax:
                    type: string
                    example: '0.00'
      tags:
        - 'ECommerce Orders'
      security: []
    put:
      summary: "Update an order's details."
      operationId: updateAnOrdersDetails
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Order updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Order updated successfully'
      tags:
        - 'ECommerce Orders'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'integer The ID of the order to update.'
                  example: dicta
                orderDate:
                  type: required
                  description: 'date The date of the order.'
                  example: maxime
                status:
                  type: required
                  description: 'string The status of the order. One of \[PENDING_PAYMENT, COMPLETED, CANCELLED, REFUNDED, FAILED, AWAITING_SHIPPING, SHIPPED].'
                  example: rerum
                customerId:
                  type: required
                  description: 'integer The ID of the customer who placed the order.'
                  example: nemo
                billingAddressId:
                  type: integer
                  description: 'The ID of the billing address for the order.'
                  example: 1
                shippingAddressId:
                  type: integer
                  description: 'The ID of the shipping address for the order.'
                  example: 2
                orderItems:
                  type: array
                  description: 'The items in the order.'
                  example:
                    - asperiores
                  items:
                    type: string
                taxAmount:
                  type: string
                  description: 'The tax amount for the order.'
                  example: et
                otherFee:
                  type: string
                  description: 'The other fee for the order.'
                  example: mollitia
      security: []
  '/api/order/{id}/status':
    put:
      summary: 'Update Order Status'
      operationId: updateOrderStatus
      description: 'To update the status of an existing order'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Order updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Order updated successfully'
      tags:
        - 'ECommerce Orders'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                status:
                  type: required
                  description: 'New status of the order. Status options: PENDING_PAYMENT, COMPLETED, CANCELLED, REFUNDED, FAILED'
                  example: sequi
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'Order ID.'
        example: '3'
        required: true
        schema:
          type: string
  /api/order-note/create:
    post:
      summary: 'Create Order Note'
      operationId: createOrderNote
      description: "To create a order note, you need to use this request.\nReturns all order notes left after this note gets created. (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    data: note-1
                    type: PRIVATE
                    created_on: 'Aug 11, 2020 05:36 PM'
      tags:
        - 'ECommerce Orders'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                data:
                  type: required
                  description: 'Note content.'
                  example: 'New notes'
                type:
                  type: required
                  description: 'Note type.'
                  example: PRIVATE
      security: []
    parameters:
      -
        in: path
        name: orderId
        description: 'Order ID.'
        example: '3'
        required: true
        schema:
          type: string
  '/api/order-note/delete/{id}':
    put:
      summary: 'Delete Order Note'
      operationId: deleteOrderNote
      description: 'Deletes an order note specified by its ID. After deletion, returns all remaining order notes for the associated order.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    data: note-1
                    type: PRIVATE
                    created_on: 'Aug 11, 2020 05:36 PM'
      tags:
        - 'ECommerce Orders'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the order note to be deleted.'
        example: '2'
        required: true
        schema:
          type: string
  /api/order/refund/lookup:
    get:
      summary: 'Refund Options Lookup'
      operationId: refundOptionsLookup
      description: "Provides the available refund options for an order, such as full refund\nor partial refund. This is useful for displaying choices in form elements\nlike dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: FULL_REFUND
                    display_value: 'Refund 100%'
                  -
                    db_value: PARTIAL_REFUND
                    display_value: 'Refund Partially'
      tags:
        - 'ECommerce Orders'
      security: []
  /api/order/note/type/lookup:
    get:
      summary: 'Order Note Type Lookup'
      operationId: orderNoteTypeLookup
      description: "Provides the available note types for an order, such as private or public.\nThis is useful for displaying choices in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: PRIVATE
                    display_value: 'Don’t show to Customer'
                  -
                    db_value: PUBLIC
                    display_value: 'Show to customer'
      tags:
        - 'ECommerce Orders'
      security: []
  /api/order/refund/type/lookup:
    get:
      summary: 'Refund Types Lookup'
      operationId: refundTypesLookup
      description: "Provides the available refund types for an order, such as stripe, braintree, authorize.net and manual.\nThis is useful for displaying choices in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: STRIPE_PAYMENT_GATEWAY
                    display_value: 'Stripe Payment Gateway'
                  -
                    db_value: BRAINTREE_PAYMENT_GATEWAY
                    display_value: 'Braintree Payment Gateway'
                  -
                    db_value: AUTHORIZENET_PAYMENT_GATEWAY
                    display_value: 'AuthorizeNet Payment Gateway'
                  -
                    db_value: MANUALLY
                    display_value: Manually
      tags:
        - 'ECommerce Orders'
      security: []
  /api/order/refund:
    post:
      summary: 'Refund an order'
      operationId: refundAnOrder
      description: "This function will allow you to process a refund of an order. The refund amount, refund reason, and refund type\nmust be provided. The refund type can be either FULL_REFUND or PARTIAL_REFUND. The refund amount is required if\nthe refund type is PARTIAL_REFUND, and the refund amount must be greater than 0."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  success: true
                  message: 'Order Refunded Successfully.'
                properties:
                  success:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Order Refunded Successfully.'
      tags:
        - 'ECommerce Orders'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The ID of the order to be refunded.'
                  example: 123
                refundedVia:
                  type: string
                  description: 'The method used to process the refund. Options: MANUALLY, STRIPE.'
                  example: MANUALLY
                refundType:
                  type: string
                  description: 'The type of refund being issued. Options: FULL_REFUND, PARTIAL_REFUND.'
                  example: FULL_REFUND
                refundAmount:
                  type: numeric
                  description: 'The amount to refund. This parameter is required only if refundType is PARTIAL_REFUND.'
                  example: '50.00'
                refundReason:
                  type: string
                  description: 'The reason for issuing the refund.'
                  example: '"Product not as described"'
              required:
                - id
                - refundedVia
                - refundType
                - refundAmount
                - refundReason
      security: []
  '/api/order/refund/{id}':
    get:
      summary: 'Get all the refund orders for the given order id'
      operationId: getAllTheRefundOrdersForTheGivenOrderId
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  refundedVia: MANUALLY
                  displayRefundedVia: Manually
                  refundAmount: 100
                  refundReason: 'Product not delivered'
                  refundStatus: COMPLETED
                  refundType: FULL_REFUND
                  refundDatePaid: '2020-01-01'
                properties:
                  refundedVia:
                    type: string
                    example: MANUALLY
                  displayRefundedVia:
                    type: string
                    example: Manually
                  refundAmount:
                    type: integer
                    example: 100
                  refundReason:
                    type: string
                    example: 'Product not delivered'
                  refundStatus:
                    type: string
                    example: COMPLETED
                  refundType:
                    type: string
                    example: FULL_REFUND
                  refundDatePaid:
                    type: string
                    example: '2020-01-01'
      tags:
        - 'ECommerce Orders'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the order'
        example: harum
        required: true
        schema:
          type: string
  /api/settings/payment-gateway:
    get:
      summary: 'Get All Payment Gateways'
      operationId: getAllPaymentGateways
      description: 'Returns all Payment Gateways.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  records:
                    -
                      id: 1
                      name: Stripe
                      logo_url: 'https://www.paypalobjects.com/webstatic/en_US/i/logo/pp-logo-100x50.png'
                      is_enabled: true
                      support_recurring_payments: true
                properties:
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: Stripe
                        logo_url: 'https://www.paypalobjects.com/webstatic/en_US/i/logo/pp-logo-100x50.png'
                        is_enabled: true
                        support_recurring_payments: true
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: Stripe
                        logo_url:
                          type: string
                          example: 'https://www.paypalobjects.com/webstatic/en_US/i/logo/pp-logo-100x50.png'
                        is_enabled:
                          type: boolean
                          example: true
                        support_recurring_payments:
                          type: boolean
                          example: true
      tags:
        - 'ECommerce Payments'
      security: []
  /api/paymentmethod/updateStatus:
    put:
      summary: 'Update Status of Payment Gateway'
      operationId: updateStatusOfPaymentGateway
      description: 'Updates the status of the specified payment gateway.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - 'ECommerce Payments'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The id of the payment gateway to be updated.'
                  example: 1
                status:
                  type: boolean
                  description: 'The status of the payment gateway.'
                  example: true
              required:
                - id
                - status
      security: []
  /api/settings/stripe:
    put:
      summary: 'Update Stripe Settings'
      operationId: updateStripeSettings
      description: 'Updates the settings for Stripe payment gateway. Setting needs to be updated is mentioned in parameter. (See Parameter)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - 'ECommerce Payments'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                gatewayEnabled:
                  type: boolean
                  description: 'Enable status of stripe gateway.'
                  example: true
                paymentTitle:
                  type: string
                  description: 'Payment title for the payments.'
                  example: 'Pay by Credit or Debit Card'
                publishableKey:
                  type: string
                  description: 'Publishable key value. Example:'
                  example: expedita
                secretKey:
                  type: string
                  description: 'Secret key value. Example:'
                  example: maiores
              required:
                - gatewayEnabled
      security: []
    get:
      summary: 'Retrieve Stripe Settings'
      operationId: retrieveStripeSettings
      description: "Retrieves all the settings for Stripe payment gateway. Helps in maintaining the data\nand enable status of the Stripe settings."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  gatewayEnabled: false
                  paymentTitle: 'Pay by Credit or Debit Card'
                  publishableKey: ''
                  secretKey: ''
                  production_mode: 'no'
                properties:
                  gatewayEnabled:
                    type: boolean
                    example: false
                  paymentTitle:
                    type: string
                    example: 'Pay by Credit or Debit Card'
                  publishableKey:
                    type: string
                    example: ''
                  secretKey:
                    type: string
                    example: ''
                  production_mode:
                    type: string
                    example: 'no'
      tags:
        - 'ECommerce Payments'
      security: []
  /api/settings/authorizenet:
    put:
      summary: 'Update AuthorizeNet Settings'
      operationId: updateAuthorizeNetSettings
      description: 'Updates the settings for AuthorizeNet payment gateway. Setting needs to be updated is mentioned in parameter. (See Parameter)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - 'ECommerce Payments'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                gatewayEnabled:
                  type: boolean
                  description: 'Enable status of AuthorizeNet gateway.'
                  example: true
                paymentTitle:
                  type: string
                  description: 'Payment title for the payments.'
                  example: 'Pay via Authorize.NET'
                loginId:
                  type: string
                  description: 'Login Id from AuthorizeNet. Example:'
                  example: quasi
                transactionKey:
                  type: string
                  description: 'Transaction key value. Example:'
                  example: adipisci
                clientId:
                  type: string
                  description: 'Client Id from AuthorizeNet. Example:'
                  example: assumenda
              required:
                - gatewayEnabled
      security: []
    get:
      summary: 'Retrieve AuthorizeNet Settings'
      operationId: retrieveAuthorizeNetSettings
      description: 'Retrieves all the settings for AuthorizeNet payment gateway. Helps in mainting the data and enable status of the AuthorizeNet settings.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  gatewayEnabled: false
                  paymentTitle: 'Pay via Authorize.NET'
                  loginId: commodi
                  transactionKey: nihil
                  clientId: commodi
                  production_mode: 'yes'
                properties:
                  gatewayEnabled:
                    type: boolean
                    example: false
                  paymentTitle:
                    type: string
                    example: 'Pay via Authorize.NET'
                  loginId:
                    type: string
                    example: commodi
                  transactionKey:
                    type: string
                    example: nihil
                  clientId:
                    type: string
                    example: commodi
                  production_mode:
                    type: string
                    example: 'yes'
      tags:
        - 'ECommerce Payments'
      security: []
  /api/settings/braintree:
    put:
      summary: 'Update Braintree Settings'
      operationId: updateBraintreeSettings
      description: "Updates the settings for Braintree payment gateway based on the provided request parameters.\nThe settings include enabling the gateway, setting the payment title, and updating merchant credentials\nfor either live or test mode depending on the production mode status."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - 'ECommerce Payments'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                gatewayEnabled:
                  type: boolean
                  description: 'Enable status of Braintree gateway.'
                  example: true
                paymentTitle:
                  type: string
                  description: 'Payment title for the payments.'
                  example: 'Pay by Credit or Debit Card'
                merchantId:
                  type: string
                  description: 'Merchant Id value.'
                  example: your_merchant_id
                publicKey:
                  type: string
                  description: 'Public Key value.'
                  example: your_public_key
                privateKey:
                  type: string
                  description: 'Private key value.'
                  example: your_private_key
                authorizationKey:
                  type: string
                  description: 'Authorization key value.'
                  example: your_authorization_key
              required:
                - gatewayEnabled
      security: []
    get:
      summary: 'Retrieves all the settings for Braintree payment gateway. Helps in mainting the data and enable status of the Braintree settings.'
      operationId: retrievesAllTheSettingsForBraintreePaymentGatewayHelpsInMaintingTheDataAndEnableStatusOfTheBraintreeSettings
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  gatewayEnabled: false
                  paymentTitle: 'Pay by Credit or Debit Card'
                  merchantId: ''
                  publicKey: ''
                  privateKey: ''
                  authorizationKey: ''
                  production_mode: 'yes'
                properties:
                  gatewayEnabled:
                    type: boolean
                    example: false
                  paymentTitle:
                    type: string
                    example: 'Pay by Credit or Debit Card'
                  merchantId:
                    type: string
                    example: ''
                  publicKey:
                    type: string
                    example: ''
                  privateKey:
                    type: string
                    example: ''
                  authorizationKey:
                    type: string
                    example: ''
                  production_mode:
                    type: string
                    example: 'yes'
      tags:
        - 'ECommerce Payments'
      security: []
  /api/settings/paypal:
    get:
      summary: 'Retrieve Paypal Settings'
      operationId: retrievePaypalSettings
      description: 'Retrieves all the settings for Paypal payment gateway. Helps in mainting the data and enable status of the Paypal settings.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  gatewayEnabled: false
                  paymentTitle: Paypal
                  clientId: ''
                  notificationUrl: 'https://staging.aomlms.com/api/webhook/paypal'
                  production_mode: 'yes'
                properties:
                  gatewayEnabled:
                    type: boolean
                    example: false
                  paymentTitle:
                    type: string
                    example: Paypal
                  clientId:
                    type: string
                    example: ''
                  notificationUrl:
                    type: string
                    example: 'https://staging.aomlms.com/api/webhook/paypal'
                  production_mode:
                    type: string
                    example: 'yes'
      tags:
        - 'ECommerce Payments'
      security: []
    put:
      summary: 'Update Paypal Settings'
      operationId: updatePaypalSettings
      description: "Updates the settings for Paypal payment gateway based on the provided request parameters.\nThe settings include enabling the gateway, setting the payment title, and updating client credentials\nfor either live or test mode depending on the production mode status."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - 'ECommerce Payments'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                gatewayEnabled:
                  type: boolean
                  description: 'Enable status of Braintree gateway.'
                  example: true
                paymentTitle:
                  type: string
                  description: 'Payment title for the payments.'
                  example: 'Pay by Credit or Debit Card'
                clientId:
                  type: string
                  description: 'Client Id value.'
                  example: your_client_id
                secretKey:
                  type: string
                  description: 'Secret key value.'
                  example: your_secret_key
              required:
                - gatewayEnabled
      security: []
  /api/settings/invoice:
    put:
      summary: 'Update Invoice Settings'
      operationId: updateInvoiceSettings
      description: 'Updates the settings for Invoice payment gateway. Setting needs to be updated is mentioned in parameter. (See Parameter)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - 'ECommerce Payments'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                gatewayEnabled:
                  type: boolean
                  description: 'Enable status of Invoice gateway.'
                  example: true
                paymentTitle:
                  type: string
                  description: 'Payment title for the payments.'
                  example: 'Pay by Invoice'
                paymentInstructions:
                  type: string
                  description: 'Payment instructions for the payments.'
                  example: 'Instructions for payment'
              required:
                - gatewayEnabled
      security: []
    get:
      summary: 'Retrieve Invoice Settings'
      operationId: retrieveInvoiceSettings
      description: "Retrieves all the settings for the Invoice payment gateway. This includes the enable status,\npayment title, and payment instructions. Useful for maintaining and displaying the current\nconfiguration of the Invoice gateway."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  gatewayEnabled: false
                  paymentTitle: 'Pay by Invoice'
                  paymentInstructions: 'Instructions for payment'
                properties:
                  gatewayEnabled:
                    type: boolean
                    example: false
                  paymentTitle:
                    type: string
                    example: 'Pay by Invoice'
                  paymentInstructions:
                    type: string
                    example: 'Instructions for payment'
      tags:
        - 'ECommerce Payments'
      security: []
  /api/settings/cashnet:
    put:
      summary: 'Update Cashnet Settings'
      operationId: updateCashnetSettings
      description: 'Updates the settings for Cashnet payment gateway. Setting needs to be updated is mentioned in parameter. (See Parameter)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - 'ECommerce Payments'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                gatewayEnabled:
                  type: boolean
                  description: 'Enable status of Cashnet gateway.'
                  example: true
                paymentTitle:
                  type: string
                  description: 'Payment title for the payments.'
                  example: 'Pay by Credit or Debit Card'
                merchantId:
                  type: string
                  description: 'Merchant Id value. Example:'
                  example: explicabo
                apiKey:
                  type: string
                  description: 'API Key value. Example:'
                  example: quo
                apiEnvUrl:
                  type: string
                  description: 'API Environment URL value.'
                  example: 'https://api.sandbox.cashnet.com/api/v1'
              required:
                - gatewayEnabled
      security: []
    get:
      summary: 'Retrieve Cashnet Settings'
      operationId: retrieveCashnetSettings
      description: "Retrieves all the settings for Cashnet payment gateway. This includes the enable status,\npayment title, merchant id, api key, api environment url and production mode status. Useful for\nmaintaining and displaying the current configuration of the Cashnet gateway."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  gatewayEnabled: false
                  paymentTitle: 'Pay by Credit or Debit Card'
                  merchantId: your_merchant_code
                  apiKey: your_api_key
                  apiEnvUrl: 'https://api.sandbox.cashnet.com/api/v1'
                  production_mode: 'yes'
                properties:
                  gatewayEnabled:
                    type: boolean
                    example: false
                  paymentTitle:
                    type: string
                    example: 'Pay by Credit or Debit Card'
                  merchantId:
                    type: string
                    example: your_merchant_code
                  apiKey:
                    type: string
                    example: your_api_key
                  apiEnvUrl:
                    type: string
                    example: 'https://api.sandbox.cashnet.com/api/v1'
                  production_mode:
                    type: string
                    example: 'yes'
      tags:
        - 'ECommerce Payments'
      security: []
  /api/products/catalog:
    get:
      summary: 'Retrieve Product Catalog'
      operationId: retrieveProductCatalog
      description: 'Retrieves the details for the product catalogs in paginated form to show this to students as course catalog so that they can purchase the product hence course.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The amount of records to return per page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The amount of records to return per page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'The page number of the records to return.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The page number of the records to return.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'The order by parameters.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: true
          schema:
            type: string
            description: 'The order by parameters.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'The search parameters.'
          example: '{"title":"", "ids":"", "selectedPrice":["Paid", "Free"], "selectedProductCategories":[], "selectedCourseType":[]}'
          required: true
          schema:
            type: string
            description: 'The search parameters.'
            example: '{"title":"", "ids":"", "selectedPrice":["Paid", "Free"], "selectedProductCategories":[], "selectedCourseType":[]}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      title: Product-1
                      slug: product-1
                      featuredImage: 'https://example.com/product-1.jpg'
                      displayPrice: 3000
                      status: IN-STOCK
                      label: SIMPLE
                      display_label: Simple
                      canBePurchased: true
                      seo_description: 'This is the description of product 1.'
                      price: 3000
                      type: SIMPLE
                      price_frequency: MONTHLY
                      webinarsCount: 1
                      modulesCount: 2
                      averageRating: 4.5
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        title: Product-1
                        slug: product-1
                        featuredImage: 'https://example.com/product-1.jpg'
                        displayPrice: 3000
                        status: IN-STOCK
                        label: SIMPLE
                        display_label: Simple
                        canBePurchased: true
                        seo_description: 'This is the description of product 1.'
                        price: 3000
                        type: SIMPLE
                        price_frequency: MONTHLY
                        webinarsCount: 1
                        modulesCount: 2
                        averageRating: 4.5
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: Product-1
                        slug:
                          type: string
                          example: product-1
                        featuredImage:
                          type: string
                          example: 'https://example.com/product-1.jpg'
                        displayPrice:
                          type: integer
                          example: 3000
                        status:
                          type: string
                          example: IN-STOCK
                        label:
                          type: string
                          example: SIMPLE
                        display_label:
                          type: string
                          example: Simple
                        canBePurchased:
                          type: boolean
                          example: true
                        seo_description:
                          type: string
                          example: 'This is the description of product 1.'
                        price:
                          type: integer
                          example: 3000
                        type:
                          type: string
                          example: SIMPLE
                        price_frequency:
                          type: string
                          example: MONTHLY
                        webinarsCount:
                          type: integer
                          example: 1
                        modulesCount:
                          type: integer
                          example: 2
                        averageRating:
                          type: number
                          example: 4.5
      tags:
        - 'ECommerce Products'
      security: []
  '/api/product/{id}':
    get:
      summary: 'Retrieves the product details.'
      operationId: retrievesTheProductDetails
      description: 'Fetches the product details, including the title, slug, description, featured image url, regular price, sale price, status, expiry date, dynamic pricing, SEO title, SEO description, display price, can be purchased, label, display label, subscription price, price frequency, free trial value, free trial frequency, subscription expire after, membership id, content access type, catalog rank, global product setting color, sale tax, tax class id, average rating, min purchase quantity, webinars count, modules count, dynamic prices, categories, related products, courses, course categories, instructor led course, learning paths, learning path categories, category courses and category learning paths.'
      parameters:
        -
          in: query
          name: id
          description: 'The ID of the product to retrieve.'
          example: provident
          required: true
          schema:
            type: string
            description: 'The ID of the product to retrieve.'
            example: provident
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  title: Product-1
                  slug: product-1
                  description: 'This is the description of product 1.'
                  featuredImageUrl: 'https://example.com/product-1.jpg'
                  regular_price: 3500
                  type: SIMPLE
                  sale_price: 3000
                  saleStartDate: '2021-01-01 12:00:00'
                  saleEndDate: '2021-01-15 12:00:00'
                  status: IN-STOCK
                  expiry_date: '2021-01-31 12:00:00'
                  dynamic_pricing: true
                  seo_title: Product-1
                  seo_description: 'This is the description of product 1.'
                  displayPrice: 3000
                  canBePurchased: true
                  label: SIMPLE
                  display_label: Simple
                  subscription_price: 3000
                  price_frequency: MONTHLY
                  free_trial_value: 1
                  free_trial_frequency: MONTHLY
                  subscription_expire_after: '2021-01-31 12:00:00'
                  membership_id: 1
                  contentAccessType: PHYSICAL
                  catalog_rank: 1
                  globalProductSettingColor:
                    product_price_color:
                      backgroundColor: '#fff'
                  saleTax: 0
                  taxClassId: 1
                  averageRating: 4.5
                  minPurchaseQuantity: 1
                  webinarsCount: 1
                  modulesCount: 2
                  dynamicPrices:
                    -
                      minQty: 1
                      maxQty: 10
                      perPrice: 3000
                  categories:
                    - 1
                    - 2
                  relatedProducts:
                    - 1
                    - 2
                  courses:
                    -
                      value: 1
                      label: Course-1
                    -
                      value: 2
                      label: Course-2
                  courseCategories:
                    - 1
                    - 2
                  instructorLedCourse:
                    -
                      value: 1
                      label: 'Instructor Led Course-1'
                  learningPaths:
                    -
                      value: 1
                      label: 'Learning Path-1'
                      learningPathCourses:
                        -
                          id: 1
                          name: Course-1
                        -
                          id: 2
                          name: Course-2
                  categoryCourses:
                    -
                      value: 3
                      label: Course-3
                  categoryLearningPaths:
                    -
                      value: 2
                      label: 'Learning Path-2'
                      learningPathCourses:
                        -
                          id: 3
                          name: Course-3
                        -
                          id: 4
                          name: Course-4
                properties:
                  id:
                    type: integer
                    example: 1
                  title:
                    type: string
                    example: Product-1
                  slug:
                    type: string
                    example: product-1
                  description:
                    type: string
                    example: 'This is the description of product 1.'
                  featuredImageUrl:
                    type: string
                    example: 'https://example.com/product-1.jpg'
                  regular_price:
                    type: integer
                    example: 3500
                  type:
                    type: string
                    example: SIMPLE
                  sale_price:
                    type: integer
                    example: 3000
                  saleStartDate:
                    type: string
                    example: '2021-01-01 12:00:00'
                  saleEndDate:
                    type: string
                    example: '2021-01-15 12:00:00'
                  status:
                    type: string
                    example: IN-STOCK
                  expiry_date:
                    type: string
                    example: '2021-01-31 12:00:00'
                  dynamic_pricing:
                    type: boolean
                    example: true
                  seo_title:
                    type: string
                    example: Product-1
                  seo_description:
                    type: string
                    example: 'This is the description of product 1.'
                  displayPrice:
                    type: integer
                    example: 3000
                  canBePurchased:
                    type: boolean
                    example: true
                  label:
                    type: string
                    example: SIMPLE
                  display_label:
                    type: string
                    example: Simple
                  subscription_price:
                    type: integer
                    example: 3000
                  price_frequency:
                    type: string
                    example: MONTHLY
                  free_trial_value:
                    type: integer
                    example: 1
                  free_trial_frequency:
                    type: string
                    example: MONTHLY
                  subscription_expire_after:
                    type: string
                    example: '2021-01-31 12:00:00'
                  membership_id:
                    type: integer
                    example: 1
                  contentAccessType:
                    type: string
                    example: PHYSICAL
                  catalog_rank:
                    type: integer
                    example: 1
                  globalProductSettingColor:
                    type: object
                    properties:
                      product_price_color:
                        type: object
                        properties:
                          backgroundColor:
                            type: string
                            example: '#fff'
                  saleTax:
                    type: integer
                    example: 0
                  taxClassId:
                    type: integer
                    example: 1
                  averageRating:
                    type: number
                    example: 4.5
                  minPurchaseQuantity:
                    type: integer
                    example: 1
                  webinarsCount:
                    type: integer
                    example: 1
                  modulesCount:
                    type: integer
                    example: 2
                  dynamicPrices:
                    type: array
                    example:
                      -
                        minQty: 1
                        maxQty: 10
                        perPrice: 3000
                    items:
                      type: object
                      properties:
                        minQty:
                          type: integer
                          example: 1
                        maxQty:
                          type: integer
                          example: 10
                        perPrice:
                          type: integer
                          example: 3000
                  categories:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  relatedProducts:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  courses:
                    type: array
                    example:
                      -
                        value: 1
                        label: Course-1
                      -
                        value: 2
                        label: Course-2
                    items:
                      type: object
                      properties:
                        value:
                          type: integer
                          example: 1
                        label:
                          type: string
                          example: Course-1
                  courseCategories:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  instructorLedCourse:
                    type: array
                    example:
                      -
                        value: 1
                        label: 'Instructor Led Course-1'
                    items:
                      type: object
                      properties:
                        value:
                          type: integer
                          example: 1
                        label:
                          type: string
                          example: 'Instructor Led Course-1'
                  learningPaths:
                    type: array
                    example:
                      -
                        value: 1
                        label: 'Learning Path-1'
                        learningPathCourses:
                          -
                            id: 1
                            name: Course-1
                          -
                            id: 2
                            name: Course-2
                    items:
                      type: object
                      properties:
                        value:
                          type: integer
                          example: 1
                        label:
                          type: string
                          example: 'Learning Path-1'
                        learningPathCourses:
                          type: array
                          example:
                            -
                              id: 1
                              name: Course-1
                            -
                              id: 2
                              name: Course-2
                          items:
                            type: object
                            properties:
                              id:
                                type: integer
                                example: 1
                              name:
                                type: string
                                example: Course-1
                  categoryCourses:
                    type: array
                    example:
                      -
                        value: 3
                        label: Course-3
                    items:
                      type: object
                      properties:
                        value:
                          type: integer
                          example: 3
                        label:
                          type: string
                          example: Course-3
                  categoryLearningPaths:
                    type: array
                    example:
                      -
                        value: 2
                        label: 'Learning Path-2'
                        learningPathCourses:
                          -
                            id: 3
                            name: Course-3
                          -
                            id: 4
                            name: Course-4
                    items:
                      type: object
                      properties:
                        value:
                          type: integer
                          example: 2
                        label:
                          type: string
                          example: 'Learning Path-2'
                        learningPathCourses:
                          type: array
                          example:
                            -
                              id: 3
                              name: Course-3
                            -
                              id: 4
                              name: Course-4
                          items:
                            type: object
                            properties:
                              id:
                                type: integer
                                example: 3
                              name:
                                type: string
                                example: Course-3
      tags:
        - 'ECommerce Products'
      security: []
    put:
      summary: 'Update an existing product.'
      operationId: updateAnExistingProduct
      description: "This endpoint allows updating a product's details, including its pricing, categories, related products, courses, and other properties.\nIt supports dynamic pricing and validation for product data such as description, sale prices, SEO, and tax settings."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Product updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Product updated successfully'
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Validation errors. Please check your input.'
                properties:
                  message:
                    type: string
                    example: 'Validation errors. Please check your input.'
        404:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Product not found'
                properties:
                  message:
                    type: string
                    example: 'Product not found'
      tags:
        - 'ECommerce Products'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The ID of the product to be updated.'
                  example: 1
                title:
                  type: string
                  description: 'The title of the product.'
                  example: '"New Course Title"'
                description:
                  type: string
                  description: 'The description of the product.'
                  example: '"A detailed description of the course."'
                featuredImageUrl:
                  type: string
                  description: "The URL for the product's featured image."
                  example: '"https://example.com/image.jpg"'
                regular_price:
                  type: numeric
                  description: 'The regular price of the product.'
                  example: '100.00'
                sale_price:
                  type: numeric
                  description: 'The sale price of the product.'
                  example: '80.00'
                saleStartDate:
                  type: string
                  description: 'The start date of the sale in `Y-m-d H:i:s` format.'
                  example: '"2025-04-01 00:00:00"'
                saleEndDate:
                  type: string
                  description: 'The end date of the sale in `Y-m-d H:i:s` format.'
                  example: '"2025-04-10 00:00:00"'
                status:
                  type: string
                  description: 'The status of the product. Options: "COMING-SOON", "IN-STOCK", "OUT-OF-STOCK".'
                  example: '"IN-STOCK"'
                type:
                  type: string
                  description: 'The type of the product. Options: "SIMPLE", "DOWNLOADABLE", "SUBSCRIPTION".'
                  example: '"SIMPLE"'
                categories:
                  type: array
                  description: 'The IDs of the categories associated with the product.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                courses:
                  type: array
                  description: 'The courses associated with the product.'
                  example:
                    -
                      value: 1
                    -
                      value: 2
                  items:
                    type: string
                relatedProducts:
                  type: array
                  description: 'The related product IDs.'
                  example:
                    - 101
                    - 102
                  items:
                    type: string
                dynamic_pricing:
                  type: boolean
                  description: 'Whether dynamic pricing is enabled for the product.'
                  example: true
                dynamicPrices:
                  type: array
                  description: 'An array of dynamic pricing rules.'
                  example:
                    -
                      minQty: 1
                      perPrice: 90.0
                  items:
                    type: string
                seo_title:
                  type: string
                  description: 'The SEO title for the product.'
                  example: '"Product SEO Title"'
                seo_description:
                  type: string
                  description: 'The SEO description for the product.'
                  example: '"This is a detailed product description for SEO."'
                membership_id:
                  type: integer
                  description: 'The ID of the membership associated with the product.'
                  example: 10
                subscription_price:
                  type: numeric
                  description: 'The subscription price for subscription products.'
                  example: '20.00'
                price_frequency:
                  type: string
                  description: 'The frequency of subscription payments. Options: "DAILY", "WEEKLY", "MONTHLY", "YEARLY".'
                  example: '"MONTHLY"'
                free_trial_value:
                  type: numeric
                  description: 'The free trial value for subscription products.'
                  example: '7'
                free_trial_frequency:
                  type: string
                  description: 'The frequency of the free trial. Options: "DAYS", "WEEKS", "MONTHS", "YEARS".'
                  example: '"DAYS"'
                minPurchaseQuantity:
                  type: numeric
                  description: 'The minimum purchase quantity for the product.'
                  example: '1'
                saleTax:
                  type: string
                  description: 'The tax rate for the sale.'
                  example: '"10%"'
                taxClassId:
                  type: integer
                  description: 'The ID of the tax class associated with the product.'
                  example: 1
              required:
                - id
                - title
                - description
                - status
                - type
  /api/products/webinars:
    get:
      summary: 'Get webinars for a product'
      operationId: getWebinarsForAProduct
      description: "Returns all webinars associated with the courses related to the product with the given ID.\nOptionally accepts a search parameter which can be used to filter the results by date range\nand location."
      parameters:
        -
          in: query
          name: product_id
          description: 'The ID of the product.'
          example: reprehenderit
          required: true
          schema:
            type: string
            description: 'The ID of the product.'
            example: reprehenderit
        -
          in: query
          name: search_param
          description: "optional A JSON object with two properties: 'dates' and 'location'.\n                           'dates' should be an array of two dates in the format 'Y-m-d'.\n                           'location' should be the ID of a location."
          example: cum
          required: false
          schema:
            type: string
            description: "optional A JSON object with two properties: 'dates' and 'location'.\n                           'dates' should be an array of two dates in the format 'Y-m-d'.\n                           'location' should be the ID of a location."
            example: cum
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  'Course Name 1':
                    -
                      id: 1
                      startDate: '2020-01-01'
                      endDate: '2020-01-01'
                      startTime: '09:00:00'
                      endTime: '17:00:00'
                      location_id: 1
                      location: 'Location 1'
                    -
                      id: 2
                      startDate: '2020-01-15'
                      endDate: '2020-01-15'
                      startTime: '09:00:00'
                      endTime: '17:00:00'
                      location_id: 2
                      location: 'Location 2'
                  'Course Name 2': []
                properties:
                  'Course Name 1':
                    type: array
                    example:
                      -
                        id: 1
                        startDate: '2020-01-01'
                        endDate: '2020-01-01'
                        startTime: '09:00:00'
                        endTime: '17:00:00'
                        location_id: 1
                        location: 'Location 1'
                      -
                        id: 2
                        startDate: '2020-01-15'
                        endDate: '2020-01-15'
                        startTime: '09:00:00'
                        endTime: '17:00:00'
                        location_id: 2
                        location: 'Location 2'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        startDate:
                          type: string
                          example: '2020-01-01'
                        endDate:
                          type: string
                          example: '2020-01-01'
                        startTime:
                          type: string
                          example: '09:00:00'
                        endTime:
                          type: string
                          example: '17:00:00'
                        location_id:
                          type: integer
                          example: 1
                        location:
                          type: string
                          example: 'Location 1'
                  'Course Name 2':
                    type: array
                    example: []
      tags:
        - 'ECommerce Products'
      security: []
  /api/get-search-product:
    post:
      summary: 'Search Products'
      operationId: searchProducts
      description: "Retrieves the products with the search_term in the product name or in the name of the courses or learning paths associated with the product.\nReturns the products in a select list format. Helps while showing products names in form elements like dropdown.\nYou can apply filters using search_term parameter. (See Response)"
      parameters:
        -
          in: query
          name: search_term
          description: 'The name or substring of the product name to search for that product.'
          example: totam
          required: true
          schema:
            type: string
            description: 'The name or substring of the product name to search for that product.'
            example: totam
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: Product-1
                    value: /product/product-1
                  -
                    id: 2
                    name: Product-2
                    value: /product/product-2
      tags:
        - 'ECommerce Products'
      security: []
  /api/products:
    get:
      summary: 'Retrieve All Products'
      operationId: retrieveAllProducts
      description: "Retrieves all the products that exists in the system.\nHelps in fetching all the products."
      parameters:
        -
          in: query
          name: excludeId
          description: 'optional ID of the product you want to exclude from the records.'
          example: '1'
          required: false
          schema:
            type: string
            description: 'optional ID of the product you want to exclude from the records.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: '[{"id":1,"title":"Product 1","slug":"product-1","description":"Course 1 product","featured_image_url":null,"regular_price":3500,"sale_price":3001,"sale_price_from":null,"sale_price_to":null,"status":"IN-STOCK","type":"SIMPLE","price_frequency":null,"site-wide-membership":null,"expired_at":"2020-10-29 00:00:00","price_includes_tax":false,"tax_rate_based_on":"CUSTOMER-BILLING-ADDR","seo_title":null,"seo_description":null,"created_by":1,"updated_by":null,"deleted_by":null,"created_at":"2020-08-11 14:12:27","updated_at":"2020-08-11 14:12:27","deleted_at":null},...]'
      tags:
        - 'ECommerce Products'
      security: []
  /api/product/type/lookup:
    get:
      summary: 'Product Type Lookup'
      operationId: productTypeLookup
      description: "Retrieves the types of the product that the platform offers.\nHelps showing options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: SIMPLE
                    display_value: Simple
                  -
                    db_value: SUBSCRIPTION
                    display_value: Subscription
      tags:
        - 'ECommerce Products'
      security: []
  '/api/products/update-slug/{id}':
    put:
      summary: 'Update Slug'
      operationId: updateSlug
      description: "Updates the slug of the product identified by 'id' with the new slug provided.\nThe new slug is checked for uniqueness and if it already exists, a new slug is generated by appending a counter to the slug.\nThe updated slug is then saved to the product.\nReturns the updated slug."
      parameters:
        -
          in: query
          name: slug
          description: 'The new slug of the product.'
          example: '"about-us"'
          required: true
          schema:
            type: string
            description: 'The new slug of the product.'
            example: '"about-us"'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: string
                example: about-us-1
      tags:
        - 'ECommerce Products'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the product to be updated.'
        example: '3'
        required: true
        schema:
          type: string
  /api/product/status/lookup:
    get:
      summary: 'Product Status Lookup'
      operationId: productStatusLookup
      description: "Retrieves the statuses for a product the platform offers.\nHelps showing options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: COMING-SOON
                    display_value: 'Coming Soon'
                  -
                    db_value: IN-STOCK
                    display_value: 'In Stock'
                  -
                    db_value: OUT-OF-STOCK
                    display_value: 'Out of Stock'
      tags:
        - 'ECommerce Products'
      security: []
  /api/products/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the products in a tabular list format in paginated mode.\nYou can apply filter using search_param via title, productStatus(in-stock, out-of-stock, etc) and productCategoryIds."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"title": "", "productStatus": ["IN-STOCK"], "productCategoryIds": []}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"title": "", "productStatus": ["IN-STOCK"], "productCategoryIds": []}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      title: 'Product 1'
                      regular_price: 3500
                      type: SIMPLE
                      status: IN-STOCK
                      created_at: '2021-01-01 12:00:00'
                      catalog_rank: 1
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        title: 'Product 1'
                        regular_price: 3500
                        type: SIMPLE
                        status: IN-STOCK
                        created_at: '2021-01-01 12:00:00'
                        catalog_rank: 1
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: 'Product 1'
                        regular_price:
                          type: integer
                          example: 3500
                        type:
                          type: string
                          example: SIMPLE
                        status:
                          type: string
                          example: IN-STOCK
                        created_at:
                          type: string
                          example: '2021-01-01 12:00:00'
                        catalog_rank:
                          type: integer
                          example: 1
      tags:
        - 'ECommerce Products'
      security: []
  /api/products/lookup:
    get:
      summary: 'Product Lookup'
      operationId: productLookup
      description: "Retrieves all the products in a select list format. Helps while showing products names in form elements like dropdown.\nYou can apply filters using search_term parameter. (See Response)"
      parameters:
        -
          in: query
          name: search_term
          description: 'The name or substring of the product name to search for that product.'
          example: molestiae
          required: true
          schema:
            type: string
            description: 'The name or substring of the product name to search for that product.'
            example: molestiae
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    title: Product-1
                    isShippingRequired: true
                  -
                    id: 2
                    title: Product-2
                    isShippingRequired: false
      tags:
        - 'ECommerce Products'
      security: []
  /api/product/create:
    post:
      summary: 'Create a new product.'
      operationId: createANewProduct
      description: ''
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Product created successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Product created successfully'
      tags:
        - 'ECommerce Products'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                title:
                  type: required
                  description: 'The title of the product.'
                  example: Product-1
                description:
                  type: required
                  description: 'The description of the product.'
                  example: 'Course 1 product'
                featuredImageUrl:
                  type: string
                  description: 'The featured image of the product.'
                  example: 'https://www.aom-images.com/product.jpeg'
                regular_price:
                  type: numeric
                  description: 'The regular price of the product.'
                  example: '3500'
                type:
                  type: string
                  description: 'The type of the product. Type options: SIMPLE, DOWNLOADABLE or SUBSCRIPTION.'
                  example: SIMPLE
                sale_price:
                  type: numeric
                  description: 'The sale price of the product.'
                  example: '3001'
                saleStartDate:
                  type: date
                  description: 'The sale start date of the product.'
                  example: '2020-12-01 0:00:00'
                saleEndDate:
                  type: date
                  description: 'The sale end date of the product.'
                  example: '2020-12-31 0:00:00'
                status:
                  type: string
                  description: 'The status of the product. Status options: COMING-SOON, IN-STOCK or OUT-OF-STOCK.'
                  example: IN-STOCK
                expiry:
                  type: date
                  description: 'The expiry date of the product.'
                  example: '2020-10-29 0:00:00'
                categories:
                  type: array
                  description: 'The categories of the product.'
                  example: []
                  items:
                    type: string
                courses:
                  type: array
                  description: 'The courses of the product.'
                  example:
                    - aspernatur
                  items:
                    type: string
                courseCategories:
                  type: array
                  description: 'The course categories of the product.'
                  example: []
                  items:
                    type: string
                learningPaths:
                  type: array
                  description: 'The learning paths of the product.'
                  example:
                    - omnis
                  items:
                    type: string
                learningPathCategories:
                  type: array
                  description: 'The learning path categories of the product.'
                  example: []
                  items:
                    type: string
                membership_id:
                  type: integer
                  description: 'The membership id of the product.'
                  example: 1
                seo_title:
                  type: string
                  description: 'The seo title of the product.'
                  example: awesome-product
                seo_description:
                  type: string
                  description: 'The seo description of the product.'
                  example: 'includes many good courses'
                subscription_price:
                  type: numeric
                  description: 'The subscription price of the product for the product type Subscription.'
                  example: '3500'
                price_frequency:
                  type: string
                  description: 'The price frequency to be charged for Subscription product. Price Frequency Options: DAILY, WEEKLY, MONTHLY or YEARLY.'
                  example: WEEKLY
                free_trial_value:
                  type: numeric
                  description: 'The free trail for the Subscription product.'
                  example: '5'
                free_trial_frequency:
                  type: string
                  description: 'The free trail frequency for the subscription product in which the product will be available for free. Free Trail Frequency Options: DAYS, WEEKS, MONTHS, YEARS.'
                  example: aut
                subscription_expire_after:
                  type: numeric
                  description: 'The subscription expire after for the Subscription product.'
                  example: '5'
                dynamic_pricing:
                  type: boolean
                  description: 'The dynamic pricing for the product.'
                  example: true
                taxClassId:
                  type: integer
                  description: 'The tax class id of the product.'
                  example: 1
                minPurchaseQuantity:
                  type: numeric
                  description: 'The minimum purchase quantity of the product.'
                  example: '2'
                catalog_rank:
                  type: numeric
                  description: 'The catalog rank of the product.'
                  example: '1'
                saleTax:
                  type: string
                  description: 'The sale tax of the product.'
                  example: taxable
                shippingClass:
                  type: integer
                  description: 'The shipping class of the product.'
                  example: 1
              required:
                - regular_price
                - type
                - status
                - subscription_price
                - price_frequency
      security: []
  /api/product/delete:
    post:
      summary: 'Delete product'
      operationId: deleteProduct
      description: "To delete a product, you need to use this request.\nReturns number of product deleted(if multiple selected) and also not deleted. (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '2 product(s) deleted 1 product(s) not deleted as it has active subscription. Please remove the subscription and try again.'
                  deletedProductsCount: 2
                  unDeletedProductsCount: 1
                  unDeletedProducts:
                    -
                      id: 5
                      name: Product-5
                properties:
                  message:
                    type: string
                    example: '2 product(s) deleted 1 product(s) not deleted as it has active subscription. Please remove the subscription and try again.'
                  deletedProductsCount:
                    type: integer
                    example: 2
                  unDeletedProductsCount:
                    type: integer
                    example: 1
                  unDeletedProducts:
                    type: array
                    example:
                      -
                        id: 5
                        name: Product-5
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 5
                        name:
                          type: string
                          example: Product-5
      tags:
        - 'ECommerce Products'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: array
                  description: 'All product IDs which needs to be deleted.'
                  example:
                    - 1
                    - 12
                    - 15
                  items:
                    type: string
              required:
                - delete_ids
      security: []
  '/api/product/price/{id}':
    get:
      summary: 'Get the price of the product.'
      operationId: getThePriceOfTheProduct
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  price: 3001
                properties:
                  price:
                    type: integer
                    example: 3001
        404:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: 'Product not found'
                properties:
                  error:
                    type: string
                    example: 'Product not found'
      tags:
        - 'ECommerce Products'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the product.'
        example: '1'
        required: true
        schema:
          type: string
  /api/product/quickEdit:
    post:
      summary: 'Quick Edit'
      operationId: quickEdit
      description: 'Updates the details in bulk for a specified product. Parameters is provided which needs to be updated. (See Parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Products updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Products updated Successfully'
      tags:
        - 'ECommerce Products'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                product_ids:
                  type: array
                  description: 'All product IDs which needs to be updated.'
                  example:
                    - 3
                    - 2
                  items:
                    type: string
                outofstock:
                  type: boolean
                  description: 'Whether product is out of stock.'
                  example: true
              required:
                - product_ids
                - outofstock
      security: []
  /api/product/freeTrial/lookup:
    get:
      summary: 'Product Free Trial Interval Lookup For Products'
      operationId: productFreeTrialIntervalLookupForProducts
      description: "Retrieves how often the amount will be deducted in subscription of the product, the platform offers.\nHelps showing options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: DAYS
                    display_value: Days
                  -
                    db_value: WEEKS
                    display_value: Weeks
                  -
                    db_value: MONTHS
                    display_value: Months
                  -
                    db_value: YEARS
                    display_value: Years
      tags:
        - 'ECommerce Products'
      security: []
  /api/product/subscription-price-frequency/lookup:
    get:
      summary: 'Subscription Price Frequency Lookup For Products'
      operationId: subscriptionPriceFrequencyLookupForProducts
      description: "Retrieves how often the amount will be deducted in subscription of the product, the platform offers.\nHelps showing options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: DAILY
                    display_value: 'Per day'
                  -
                    db_value: WEEKLY
                    display_value: 'Per week'
                  -
                    db_value: MONTHLY
                    display_value: 'Per month'
                  -
                    db_value: YEARLY
                    display_value: 'Per year'
      tags:
        - 'ECommerce Products'
      security: []
  /api/product/clone:
    post:
      summary: 'Clone Product'
      operationId: cloneProduct
      description: 'Clone the product with the given ID and copies all the related mappings with the product'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Product Cloned Successfully'
                properties:
                  message:
                    type: string
                    example: 'Product Cloned Successfully'
      tags:
        - 'ECommerce Products'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                productId:
                  type: required
                  description: 'The id of the product to be cloned.'
                  example: autem
      security: []
  /api/modules/flashcards:
    get:
      summary: 'Flash Cards Modules Tabular List'
      operationId: flashCardsModulesTabularList
      description: "Returns all the flash cards modules in a tabular list format in paginated mode.\nYou can apply filter using search_param via moduleTypes(module type), associatedCourse(modules used in course) and moduleName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"moduleTypes": ["flashcards"],associatedCourse":"","moduleName":""}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"moduleTypes": ["flashcards"],associatedCourse":"","moduleName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 14
                  recordsFiltered: 3
                  records:
                    -
                      id: 14
                      name: Lesson-1
                      slug: lesson-1
                      type: flashcards
                      icon: '<i class="el-icon-collection"></i>'
                      author: 'Aom Staff'
                      created_at: 'Aug 11, 2020 06:45 AM'
                    -
                      id: 5
                      name: 'The Fundamentals of LMS'
                      slug: the-fundamentals-of-lms
                      type: flashcards
                      icon: '<i class="el-icon-collection"></i>'
                      author: 'Aom Staff'
                      created_at: 'Aug 10, 2020 04:59 PM'
                    -
                      id: 1
                      name: test
                      slug: test
                      type: flashcards
                      icon: '<i class="el-icon-collection"></i>'
                      author: 'Aom Staff'
                      created_at: 'Aug 03, 2020 09:56 AM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 14
                  recordsFiltered:
                    type: integer
                    example: 3
                  records:
                    type: array
                    example:
                      -
                        id: 14
                        name: Lesson-1
                        slug: lesson-1
                        type: flashcards
                        icon: '<i class="el-icon-collection"></i>'
                        author: 'Aom Staff'
                        created_at: 'Aug 11, 2020 06:45 AM'
                      -
                        id: 5
                        name: 'The Fundamentals of LMS'
                        slug: the-fundamentals-of-lms
                        type: flashcards
                        icon: '<i class="el-icon-collection"></i>'
                        author: 'Aom Staff'
                        created_at: 'Aug 10, 2020 04:59 PM'
                      -
                        id: 1
                        name: test
                        slug: test
                        type: flashcards
                        icon: '<i class="el-icon-collection"></i>'
                        author: 'Aom Staff'
                        created_at: 'Aug 03, 2020 09:56 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 14
                        name:
                          type: string
                          example: Lesson-1
                        slug:
                          type: string
                          example: lesson-1
                        type:
                          type: string
                          example: flashcards
                        icon:
                          type: string
                          example: '<i class="el-icon-collection"></i>'
                        author:
                          type: string
                          example: 'Aom Staff'
                        created_at:
                          type: string
                          example: 'Aug 11, 2020 06:45 AM'
      tags:
        - 'Flash Cards Modules'
      security: []
    post:
      summary: 'Create FlashCard Module'
      operationId: createFlashCardModule
      description: "To create a flashcard module, you need to use this request. (See parameters)\nCreated flashcard modules can be used in the course as course content/lesson.\n\nReturns : id of the flashcard module created and successfull message"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 9
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 9
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - 'Flash Cards Modules'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the flashcard module.'
                  example: 'The Fundamentals of LMS'
                content:
                  type: string
                  description: 'Content for the flashcard modules that students will see.'
                  example: '<p>This is the short content here</p>'
                orientation:
                  type: string
                  description: 'Orientation of the flashcard module.'
                  example: portrait
                trackCompletion:
                  type: boolean
                  description: 'If true, the module is being tracked(whether its finished or not) in course player.'
                  example: true
                categories:
                  type: array
                  description: 'The module category to which the flashcard belong to.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                estimatedCompletion:
                  type: integer
                  description: 'The estimated completion time for the flashcard module.'
                  example: 2
                estimationCompletedUnit:
                  type: string
                  description: 'The unit of the estimated completion time.'
                  example: minute
              required:
                - name
                - content
                - orientation
                - trackCompletion
      security: []
  '/api/modules/flashcards/{id}':
    get:
      summary: 'Retrieve Detailed Flashcard Module Info'
      operationId: retrieveDetailedFlashcardModuleInfo
      description: "Retrieves details of flashcard module in depth.\nReturns related fields value. (See Response)"
      parameters:
        -
          in: query
          name: id
          description: 'ID of the flashcard module.'
          example: '6'
          required: true
          schema:
            type: string
            description: 'ID of the flashcard module.'
            example: '6'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 6
                  name: 'Introduction to Web Development'
                  slug: intro-to-web-development
                  content: '<p>This course covers the basics of HTML, CSS, and JavaScript for building modern websites.</p>'
                  trackCompletion: true
                  estimatedCompletion: '30'
                  estimationCompletedUnit: hours
                  orientation: Online
                  categories: []
                  courses: []
                properties:
                  id:
                    type: integer
                    example: 6
                  name:
                    type: string
                    example: 'Introduction to Web Development'
                  slug:
                    type: string
                    example: intro-to-web-development
                  content:
                    type: string
                    example: '<p>This course covers the basics of HTML, CSS, and JavaScript for building modern websites.</p>'
                  trackCompletion:
                    type: boolean
                    example: true
                  estimatedCompletion:
                    type: string
                    example: '30'
                  estimationCompletedUnit:
                    type: string
                    example: hours
                  orientation:
                    type: string
                    example: Online
                  categories:
                    type: array
                    example: []
                  courses:
                    type: array
                    example: []
      tags:
        - 'Flash Cards Modules'
      security: []
    put:
      summary: 'Update Flash Card Module'
      operationId: updateFlashCardModule
      description: "Updates the details of the specified flash card module. (See parameters)\nFlash card modules can be used in the course as course content/lesson."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Module updated successfully'
      tags:
        - 'Flash Cards Modules'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the flash card module.'
                  example: 'Basic Concepts'
                content:
                  type: array
                  description: 'Content for the flash card module.'
                  example:
                    - 'Flashcard content'
                  items:
                    type: string
                orientation:
                  type: string
                  description: 'Orientation of the flash card module.'
                  example: horizontal
                trackCompletion:
                  type: boolean
                  description: "If true, the module is being tracked (whether it's finished or not) in course player."
                  example: true
                categories:
                  type: array
                  description: 'Categories to which the flash card module belongs.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                estimatedCompletion:
                  type: nullable
                  description: 'Estimated time to complete the module.'
                  example: '30'
                estimationCompletedUnit:
                  type: nullable
                  description: 'Unit of the estimated completion time.'
                  example: minutes
              required:
                - name
                - orientation
      security: []
  /api/module/flashcards/details:
    get:
      summary: 'Retrieve Detailed Flashcard Module Info'
      operationId: retrieveDetailedFlashcardModuleInfo
      description: "Retrieves details of flashcard module in depth as well as different modules details that are being used as course content for the same course the current flashcard module is attached to.\nReturns related fields value. (See Response)"
      parameters:
        -
          in: query
          name: registrationId
          description: 'ID of the course Registration for which this module is attached to.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the course Registration for which this module is attached to.'
            example: '1'
        -
          in: query
          name: moduleId
          description: 'ID of the flashcard module.'
          example: '6'
          required: true
          schema:
            type: string
            description: 'ID of the flashcard module.'
            example: '6'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Web Development Basics'
                  slug: web-development-basics
                  content: '<p>This module introduces the core concepts of modern web development, including HTML, CSS, and responsive design.</p>'
                  courseName: 'Full Stack Web Development'
                  courseSlug: 'http://localhost:8000/course/full-stack-web-development'
                  trackCompletion: true
                  min_time_spent: 0
                  otherModules:
                    -
                      module_id: 1
                      name: 'Introduction to HTML'
                      slug: introduction-to-html
                      type: text
                      icon: '<i class="el-icon-tickets"></i>'
                      is_locked: false
                      lock_reason: ''
                      is_dripped: false
                      drip_message: ''
                      is_current: false
                      status_row_id: 1
                      status: Completed
                      started_on: '2020-08-03T10:02:33.000000Z'
                      completed_on: '2020-08-03T10:02:41.000000Z'
                      last_accessed_on: '1 week ago'
                      total_time_spent:
                        hours: 0
                        minutes: 0
                        seconds: 6
                        totalSeconds: 6
                      completion_percentage: 100
                      no_of_times_accessed: 1
                    -
                      module_id: 4
                      name: 'CSS Assignment'
                      slug: css-assignment
                      type: assignment
                      icon: '<i class="el-icon-edit-outline"></i>'
                      is_locked: false
                      lock_reason: ''
                      is_dripped: false
                      drip_message: ''
                      is_current: true
                      status_row_id: -1
                      status: 'Not Started'
                      started_on: ''
                      completed_on: ''
                      last_accessed_on: Never
                      total_time_spent: ''
                      points_awarded: ''
                      completion_percentage: 0
                      no_of_times_accessed: 0
                  launchCheck:
                    canbeLaunched: true
                    errTitle: ''
                    errDesc: ''
                  prevSlug: ''
                  nextSlug: css-assignment
                  status: Completed
                  timeSpent: 6
                  statusRowId: 1
                properties:
                  name:
                    type: string
                    example: 'Web Development Basics'
                  slug:
                    type: string
                    example: web-development-basics
                  content:
                    type: string
                    example: '<p>This module introduces the core concepts of modern web development, including HTML, CSS, and responsive design.</p>'
                  courseName:
                    type: string
                    example: 'Full Stack Web Development'
                  courseSlug:
                    type: string
                    example: 'http://localhost:8000/course/full-stack-web-development'
                  trackCompletion:
                    type: boolean
                    example: true
                  min_time_spent:
                    type: integer
                    example: 0
                  otherModules:
                    type: array
                    example:
                      -
                        module_id: 1
                        name: 'Introduction to HTML'
                        slug: introduction-to-html
                        type: text
                        icon: '<i class="el-icon-tickets"></i>'
                        is_locked: false
                        lock_reason: ''
                        is_dripped: false
                        drip_message: ''
                        is_current: false
                        status_row_id: 1
                        status: Completed
                        started_on: '2020-08-03T10:02:33.000000Z'
                        completed_on: '2020-08-03T10:02:41.000000Z'
                        last_accessed_on: '1 week ago'
                        total_time_spent:
                          hours: 0
                          minutes: 0
                          seconds: 6
                          totalSeconds: 6
                        completion_percentage: 100
                        no_of_times_accessed: 1
                      -
                        module_id: 4
                        name: 'CSS Assignment'
                        slug: css-assignment
                        type: assignment
                        icon: '<i class="el-icon-edit-outline"></i>'
                        is_locked: false
                        lock_reason: ''
                        is_dripped: false
                        drip_message: ''
                        is_current: true
                        status_row_id: -1
                        status: 'Not Started'
                        started_on: ''
                        completed_on: ''
                        last_accessed_on: Never
                        total_time_spent: ''
                        points_awarded: ''
                        completion_percentage: 0
                        no_of_times_accessed: 0
                    items:
                      type: object
                      properties:
                        module_id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Introduction to HTML'
                        slug:
                          type: string
                          example: introduction-to-html
                        type:
                          type: string
                          example: text
                        icon:
                          type: string
                          example: '<i class="el-icon-tickets"></i>'
                        is_locked:
                          type: boolean
                          example: false
                        lock_reason:
                          type: string
                          example: ''
                        is_dripped:
                          type: boolean
                          example: false
                        drip_message:
                          type: string
                          example: ''
                        is_current:
                          type: boolean
                          example: false
                        status_row_id:
                          type: integer
                          example: 1
                        status:
                          type: string
                          example: Completed
                        started_on:
                          type: string
                          example: '2020-08-03T10:02:33.000000Z'
                        completed_on:
                          type: string
                          example: '2020-08-03T10:02:41.000000Z'
                        last_accessed_on:
                          type: string
                          example: '1 week ago'
                        total_time_spent:
                          type: object
                          properties:
                            hours:
                              type: integer
                              example: 0
                            minutes:
                              type: integer
                              example: 0
                            seconds:
                              type: integer
                              example: 6
                            totalSeconds:
                              type: integer
                              example: 6
                        completion_percentage:
                          type: integer
                          example: 100
                        no_of_times_accessed:
                          type: integer
                          example: 1
                  launchCheck:
                    type: object
                    properties:
                      canbeLaunched:
                        type: boolean
                        example: true
                      errTitle:
                        type: string
                        example: ''
                      errDesc:
                        type: string
                        example: ''
                  prevSlug:
                    type: string
                    example: ''
                  nextSlug:
                    type: string
                    example: css-assignment
                  status:
                    type: string
                    example: Completed
                  timeSpent:
                    type: integer
                    example: 6
                  statusRowId:
                    type: integer
                    example: 1
      tags:
        - 'Flash Cards Modules'
      security: []
  /api/module/flashcards/updateProgress:
    put:
      summary: 'Update the progress of a flashcard module.'
      operationId: updateTheProgressOfAFlashcardModule
      description: ''
      parameters:
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: '5'
          required: true
          schema:
            type: string
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: '5'
        -
          in: query
          name: statusRowId
          description: 'ID of the ModuleStatus Row belongs to current flashcard module.'
          example: '6'
          required: true
          schema:
            type: string
            description: 'ID of the ModuleStatus Row belongs to current flashcard module.'
            example: '6'
        -
          in: query
          name: cardIndex
          description: 'The current index of the card being accessed.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current index of the card being accessed.'
            example: '1'
        -
          in: query
          name: totalCards
          description: 'The total number of cards in the current module.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The total number of cards in the current module.'
            example: '10'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: Completed
                  message: 'Module completed successfully'
                  course_newly_completed: false
                properties:
                  status:
                    type: string
                    example: Completed
                  message:
                    type: string
                    example: 'Module completed successfully'
                  course_newly_completed:
                    type: boolean
                    example: false
      tags:
        - 'Flash Cards Modules'
      security: []
  /api/module/flashcards/content-details:
    get:
      summary: 'Retrieve Detailed Flashcard Module Info as Membership content'
      operationId: retrieveDetailedFlashcardModuleInfoAsMembershipContent
      description: "Retrieves details of flashcard module in depth for the same membership the current flashcard module is attached to.\nReturns related fields value. (See Response)"
      parameters:
        -
          in: query
          name: moduleId
          description: 'ID of the flashcard module.'
          example: '6'
          required: true
          schema:
            type: string
            description: 'ID of the flashcard module.'
            example: '6'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'JavaScript Flashcards'
                  slug: javascript-flashcards
                  content: '<p>Practice key JavaScript concepts through interactive flashcards.</p>'
                  url: 'http://localhost:8000/storage/uploads/module/6/flashcards/flashcard1/slide1/slide1.html'
                  orientation: landscape
                  trackCompletion: true
                  timeSpent: null
                properties:
                  name:
                    type: string
                    example: 'JavaScript Flashcards'
                  slug:
                    type: string
                    example: javascript-flashcards
                  content:
                    type: string
                    example: '<p>Practice key JavaScript concepts through interactive flashcards.</p>'
                  url:
                    type: string
                    example: 'http://localhost:8000/storage/uploads/module/6/flashcards/flashcard1/slide1/slide1.html'
                  orientation:
                    type: string
                    example: landscape
                  trackCompletion:
                    type: boolean
                    example: true
                  timeSpent:
                    type: string
                    example: null
      tags:
        - 'Flash Cards Modules'
      security: []
  /api/integrations/webhook/eventLookup:
    get:
      summary: 'Webhook Event Lookup'
      operationId: webhookEventLookup
      description: "Retrieves all the events for the webhook actions.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: new_account_created
                    display_value: 'New Account Created'
                  -
                    db_value: course_enrolled
                    display_value: 'Enrolled in a course'
                  -
                    db_value: quiz_submission
                    display_value: 'Submitted a Quiz'
                  -
                    db_value: assigment_submission
                    display_value: 'Submitted an assignment'
                  -
                    db_value: assigment_evaluation
                    display_value: 'Evaluated an assignment'
                  -
                    db_value: assigment_rejection
                    display_value: 'Rejected an assignment'
                  -
                    db_value: discussion_submission
                    display_value: 'Submitted a discussion'
                  -
                    db_value: new_order
                    display_value: 'New Order Placed'
                  -
                    db_value: failed_order
                    display_value: 'Order Failed'
                  -
                    db_value: refunded_order
                    display_value: 'Order Refunded'
                  -
                    db_value: pending_payment
                    display_value: 'Payment Pending'
                  -
                    db_value: new_announcement
                    display_value: 'New Announcement'
                  -
                    db_value: course_completed
                    display_value: 'Course Completed'
      tags:
        - 'Front End Webhook API'
      security: []
  /api/webhook/create:
    post:
      summary: 'Create Webhook'
      operationId: createWebhook
      description: "Creates a webhook using parameters mentioned. (See parameters)\nCreates the webhook details using webhook ID."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: '4'
                  message: 'Webhook saved successfully'
                properties:
                  id:
                    type: string
                    example: '4'
                  message:
                    type: string
                    example: 'Webhook saved successfully'
      tags:
        - 'Front End Webhook API'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                url:
                  type: string
                  description: 'Endpoint to send the data.'
                  example: 'https://example.aom'
                description:
                  type: string
                  description: 'Description of the event that is being created.'
                  example: 'It will use to collect new user data.'
                eventList:
                  type: string
                  description: 'Event from the option list. Event options: new_account_created, course_enrolled, quiz_submission, assigment_submission, assigment_evaluation, assigment_rejection, discussion_submission, new_order, failed_order, refunded_order, pending_payment, new_announcement or course_completed.'
                  example: 'New Account Created'
              required:
                - url
                - eventList
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the webhook.'
        example: '3'
        required: true
        schema:
          type: string
  /api/webhooks:
    get:
      summary: 'Webhook Actions Tabular List'
      operationId: webhookActionsTabularList
      description: "Returns all the Webhook created in a tabular list format.\nYou can apply filter using search_param."
      parameters:
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'For searching items based on Events.'
          example: 0
          required: false
          schema:
            type: integer
            description: 'For searching items based on Events.'
            example: 0
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 4
                  recordsFiltered: 3
                  records:
                    -
                      id: 3
                      url: 'https://example.aom.com'
                      events: 'New Account Created'
                      author: 'Client Admin'
                      created_at: 'Aug 10, 2020 12:43 PM'
                    -
                      id: 4
                      url: 'https://example.aom.com'
                      events: 'Enrolled in a course'
                      author: 'Client Admin'
                      created_at: 'Aug 10, 2020 12:43 PM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 4
                  recordsFiltered:
                    type: integer
                    example: 3
                  records:
                    type: array
                    example:
                      -
                        id: 3
                        url: 'https://example.aom.com'
                        events: 'New Account Created'
                        author: 'Client Admin'
                        created_at: 'Aug 10, 2020 12:43 PM'
                      -
                        id: 4
                        url: 'https://example.aom.com'
                        events: 'Enrolled in a course'
                        author: 'Client Admin'
                        created_at: 'Aug 10, 2020 12:43 PM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 3
                        url:
                          type: string
                          example: 'https://example.aom.com'
                        events:
                          type: string
                          example: 'New Account Created'
                        author:
                          type: string
                          example: 'Client Admin'
                        created_at:
                          type: string
                          example: 'Aug 10, 2020 12:43 PM'
      tags:
        - 'Front End Webhook API'
      security: []
  '/api/webhook/{id}':
    put:
      summary: 'Update the specified webhook in storage.'
      operationId: updateTheSpecifiedWebhookInStorage
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: '4'
                  message: 'Webhook updated successfully'
                properties:
                  id:
                    type: string
                    example: '4'
                  message:
                    type: string
                    example: 'Webhook updated successfully'
      tags:
        - 'Front End Webhook API'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                url:
                  type: string
                  description: 'Endpoint to send the data.'
                  example: 'https://example.aom'
                description:
                  type: string
                  description: 'Description of the event that is being created.'
                  example: 'It will use to collect new user data.'
                eventList:
                  type: string
                  description: 'Event from the option list. Event options: new_account_created, course_enrolled, quiz_submission, assigment_submission, assigment_evaluation, assigment_rejection, discussion_submission, new_order, failed_order, refunded_order, pending_payment, new_announcement or course_completed.'
                  example: 'New Account Created'
              required:
                - url
                - eventList
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the webhook.'
        example: '3'
        required: true
        schema:
          type: string
  '/api/webhook/delete/{id}':
    delete:
      summary: 'Delete the specified webhook in storage.'
      operationId: deleteTheSpecifiedWebhookInStorage
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Webhook deleted successfully'
                properties:
                  message:
                    type: string
                    example: 'Webhook deleted successfully'
      tags:
        - 'Front End Webhook API'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the webhook.'
        example: '3'
        required: true
        schema:
          type: string
  '/api/webhook/logs/{id}':
    get:
      summary: 'Webhook Log Tabular List'
      operationId: webhookLogTabularList
      description: 'Returns all the webhook log in a tabular list format in paginated mode.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'For searching items based on columns provided in JSON format.'
          example: 0
          required: false
          schema:
            type: integer
            description: 'For searching items based on columns provided in JSON format.'
            example: 0
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      event: new_account_created
                      data: []
                      status: success
                      errorMessage: ''
                      created_at: 'Aug 03, 2020 09:56 AM'
                      showData: false
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        event: new_account_created
                        data: []
                        status: success
                        errorMessage: ''
                        created_at: 'Aug 03, 2020 09:56 AM'
                        showData: false
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        event:
                          type: string
                          example: new_account_created
                        data:
                          type: array
                          example: []
                        status:
                          type: string
                          example: success
                        errorMessage:
                          type: string
                          example: ''
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        showData:
                          type: boolean
                          example: false
      tags:
        - 'Front End Webhook API'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the webhook.'
        example: '3'
        required: true
        schema:
          type: string
  /api/integrations/mailchimp/eventLookup:
    get:
      summary: 'Mailchimp Event Lookup'
      operationId: mailchimpEventLookup
      description: "Retrieves all the events for the mailchimp actions.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: newAccount
                    display_value: 'Add New Account'
      tags:
        - 'Front End Webhook API'
      security: []
  /api/mailchimp/create:
    post:
      summary: 'Create a new Mailchimp event'
      operationId: createANewMailchimpEvent
      description: ''
      parameters:
        -
          in: query
          name: data
          description: 'An array of webhooks to be saved.'
          example: '[{"list_id": "1234567890", "list_name": "Test list", "event": "subscribe"}]'
          required: true
          schema:
            type: string
            description: 'An array of webhooks to be saved.'
            example: '[{"list_id": "1234567890", "list_name": "Test list", "event": "subscribe"}]'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Mailchimp saved successfully'
                properties:
                  message:
                    type: string
                    example: 'Mailchimp saved successfully'
      tags:
        - 'Front End Webhook API'
      security: []
  /api/mailchimp/getList:
    get:
      summary: 'Get all Mailchimp lists'
      operationId: getAllMailchimpLists
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  lists:
                    -
                      id: a1b2c3d4e5
                      name: 'Weekly Newsletter'
                      contact:
                        company: 'Acme Corp'
                        address1: '123 Main Street'
                        address2: 'Suite 400'
                        city: 'New York'
                        state: NY
                        zip: '10001'
                        country: US
                        phone: +1-555-123-4567
                      permission_reminder: 'You are receiving this email because you signed up on our website.'
                      use_archive_bar: true
                      campaign_defaults:
                        from_name: 'Marketing Team'
                        from_email: marketing@acmecorp.com
                        subject: 'Your Weekly Update from Acme Corp'
                        language: en
                      notify_on_subscribe: subscribe@acmecorp.com
                      notify_on_unsubscribe: unsubscribe@acmecorp.com
                      email_type_option: true
                      visibility: pub
                      double_optin: true
                      marketing_permissions: true
                      modules:
                        - ecommerce
                        - social_media
                      stats:
                        member_count: 2500
                        unsubscribe_count: 45
                        cleaned_count: 12
                        member_count_since_send: 30
                        unsubscribe_count_since_send: 3
                        cleaned_count_since_send: 1
                        campaign_count: 52
                        campaign_last_sent: '2024-04-10T10:00:00+00:00'
                        merge_field_count: 5
                        avg_sub_rate: 2.5
                        avg_unsub_rate: 0.3
                        target_sub_rate: 3.0
                        open_rate: 36.5
                        click_rate: 8.7
                      date_created: '2023-01-15T09:30:00+00:00'
                properties:
                  lists:
                    type: array
                    example:
                      -
                        id: a1b2c3d4e5
                        name: 'Weekly Newsletter'
                        contact:
                          company: 'Acme Corp'
                          address1: '123 Main Street'
                          address2: 'Suite 400'
                          city: 'New York'
                          state: NY
                          zip: '10001'
                          country: US
                          phone: +1-555-123-4567
                        permission_reminder: 'You are receiving this email because you signed up on our website.'
                        use_archive_bar: true
                        campaign_defaults:
                          from_name: 'Marketing Team'
                          from_email: marketing@acmecorp.com
                          subject: 'Your Weekly Update from Acme Corp'
                          language: en
                        notify_on_subscribe: subscribe@acmecorp.com
                        notify_on_unsubscribe: unsubscribe@acmecorp.com
                        email_type_option: true
                        visibility: pub
                        double_optin: true
                        marketing_permissions: true
                        modules:
                          - ecommerce
                          - social_media
                        stats:
                          member_count: 2500
                          unsubscribe_count: 45
                          cleaned_count: 12
                          member_count_since_send: 30
                          unsubscribe_count_since_send: 3
                          cleaned_count_since_send: 1
                          campaign_count: 52
                          campaign_last_sent: '2024-04-10T10:00:00+00:00'
                          merge_field_count: 5
                          avg_sub_rate: 2.5
                          avg_unsub_rate: 0.3
                          target_sub_rate: 3
                          open_rate: 36.5
                          click_rate: 8.7
                        date_created: '2023-01-15T09:30:00+00:00'
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          example: a1b2c3d4e5
                        name:
                          type: string
                          example: 'Weekly Newsletter'
                        contact:
                          type: object
                          properties:
                            company:
                              type: string
                              example: 'Acme Corp'
                            address1:
                              type: string
                              example: '123 Main Street'
                            address2:
                              type: string
                              example: 'Suite 400'
                            city:
                              type: string
                              example: 'New York'
                            state:
                              type: string
                              example: NY
                            zip:
                              type: string
                              example: '10001'
                            country:
                              type: string
                              example: US
                            phone:
                              type: string
                              example: +1-555-123-4567
                        permission_reminder:
                          type: string
                          example: 'You are receiving this email because you signed up on our website.'
                        use_archive_bar:
                          type: boolean
                          example: true
                        campaign_defaults:
                          type: object
                          properties:
                            from_name:
                              type: string
                              example: 'Marketing Team'
                            from_email:
                              type: string
                              example: marketing@acmecorp.com
                            subject:
                              type: string
                              example: 'Your Weekly Update from Acme Corp'
                            language:
                              type: string
                              example: en
                        notify_on_subscribe:
                          type: string
                          example: subscribe@acmecorp.com
                        notify_on_unsubscribe:
                          type: string
                          example: unsubscribe@acmecorp.com
                        email_type_option:
                          type: boolean
                          example: true
                        visibility:
                          type: string
                          example: pub
                        double_optin:
                          type: boolean
                          example: true
                        marketing_permissions:
                          type: boolean
                          example: true
                        modules:
                          type: array
                          example:
                            - ecommerce
                            - social_media
                          items:
                            type: string
                        stats:
                          type: object
                          properties:
                            member_count:
                              type: integer
                              example: 2500
                            unsubscribe_count:
                              type: integer
                              example: 45
                            cleaned_count:
                              type: integer
                              example: 12
                            member_count_since_send:
                              type: integer
                              example: 30
                            unsubscribe_count_since_send:
                              type: integer
                              example: 3
                            cleaned_count_since_send:
                              type: integer
                              example: 1
                            campaign_count:
                              type: integer
                              example: 52
                            campaign_last_sent:
                              type: string
                              example: '2024-04-10T10:00:00+00:00'
                            merge_field_count:
                              type: integer
                              example: 5
                            avg_sub_rate:
                              type: number
                              example: 2.5
                            avg_unsub_rate:
                              type: number
                              example: 0.3
                            target_sub_rate:
                              type: number
                              example: 3.0
                            open_rate:
                              type: number
                              example: 36.5
                            click_rate:
                              type: number
                              example: 8.7
                        date_created:
                          type: string
                          example: '2023-01-15T09:30:00+00:00'
      tags:
        - 'Front End Webhook API'
      security: []
  /api/mailchimp/getMailchimpEvents:
    get:
      summary: 'Mailchimp Actions Tabular List'
      operationId: mailchimpActionsTabularList
      description: "Returns all the Mailchimp Actions created in a tabular list format.\nYou can apply filter using search_param."
      parameters:
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 4
                  recordsFiltered: 3
                  records:
                    -
                      id: 3
                      list_name: AOM
                      event: 'New Account Created'
                      author: 'Client Admin'
                      created_at: 'Aug 10, 2020 12:43 PM'
                    -
                      id: 4
                      list_name: AOM
                      event: 'Enrolled in a course'
                      author: 'Client Admin'
                      created_at: 'Aug 10, 2020 12:43 PM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 4
                  recordsFiltered:
                    type: integer
                    example: 3
                  records:
                    type: array
                    example:
                      -
                        id: 3
                        list_name: AOM
                        event: 'New Account Created'
                        author: 'Client Admin'
                        created_at: 'Aug 10, 2020 12:43 PM'
                      -
                        id: 4
                        list_name: AOM
                        event: 'Enrolled in a course'
                        author: 'Client Admin'
                        created_at: 'Aug 10, 2020 12:43 PM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 3
                        list_name:
                          type: string
                          example: AOM
                        event:
                          type: string
                          example: 'New Account Created'
                        author:
                          type: string
                          example: 'Client Admin'
                        created_at:
                          type: string
                          example: 'Aug 10, 2020 12:43 PM'
      tags:
        - 'Front End Webhook API'
      security: []
  '/api/mailchimp/logs/{id}':
    get:
      summary: 'Mailchimp Log Tabular List'
      operationId: mailchimpLogTabularList
      description: 'Returns all the Mailchimp log in a tabular list format in paginated mode.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'For searching items based on field names.'
          example: '{"name":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on field names.'
            example: '{"name":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      event: new_account_created
                      data: []
                      status: success
                      errorMessage: ''
                      created_at: 'Aug 03, 2020 09:56 AM'
                      showData: false
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        event: new_account_created
                        data: []
                        status: success
                        errorMessage: ''
                        created_at: 'Aug 03, 2020 09:56 AM'
                        showData: false
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        event:
                          type: string
                          example: new_account_created
                        data:
                          type: array
                          example: []
                        status:
                          type: string
                          example: success
                        errorMessage:
                          type: string
                          example: ''
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        showData:
                          type: boolean
                          example: false
      tags:
        - 'Front End Webhook API'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the Mailchimp action.'
        example: '50'
        required: true
        schema:
          type: string
  /api/gamification_events/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: 'Retrieves all the gamification events in a tabular list format.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  records:
                    -
                      id: 1
                      name: 'Test Gamification Event'
                      triggerValue: 100
                      badgeTitle: 'Test Badge'
                      type: total_money_spent
                      display_type: 'Total money spent'
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Test Gamification Event'
                        triggerValue: 100
                        badgeTitle: 'Test Badge'
                        type: total_money_spent
                        display_type: 'Total money spent'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Test Gamification Event'
                        triggerValue:
                          type: integer
                          example: 100
                        badgeTitle:
                          type: string
                          example: 'Test Badge'
                        type:
                          type: string
                          example: total_money_spent
                        display_type:
                          type: string
                          example: 'Total money spent'
      tags:
        - Gamification
      security: []
  /api/gamification_events/eventTypeLookUp:
    get:
      summary: 'Retrieves all the types of events for gamification event settings.'
      operationId: retrievesAllTheTypesOfEventsForGamificationEventSettings
      description: 'Helps showing options in dropdowns elements'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "[\n    ['db_value' => 'total_money_spent', 'display_value' => 'Total money spent'] ,\n    ['db_value' => 'total_time_spent', 'display_value' => 'Total time spent learning(in hrs)'] ,\n    ['db_value' => 'total_module_completed', 'display_value' => 'No. of modules completed'] ,\n    ['db_value' => 'total_course_completed', 'display_value' => 'No. of courses completed'] ,\n]"
      tags:
        - Gamification
      security: []
  /api/gamification_event/create:
    post:
      summary: 'Create a new gamification event.'
      operationId: createANewGamificationEvent
      description: 'Creates a new gamification event with the given name, type, selected badge ID, and trigger value.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 4
                  message: 'Event created successfully'
                properties:
                  id:
                    type: integer
                    example: 4
                  message:
                    type: string
                    example: 'Event created successfully'
      tags:
        - Gamification
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: required
                  description: 'string The name of the new event.'
                  example: '"New Event"'
                eventType:
                  type: required
                  description: 'string The type of the new event.'
                  example: '"total_money_spent"'
                selectedBadgeId:
                  type: required
                  description: 'The ID of the selected badge.'
                  example: '123'
                triggerValue:
                  type: required
                  description: 'integer The trigger value for the new event.'
                  example: '5.6'
      security: []
  '/api/gamification_event/{id}':
    get:
      summary: 'Retrieve a specific gamification event.'
      operationId: retrieveASpecificGamificationEvent
      description: "Fetches the details of a gamification event by its ID, including\nthe event name, type, selected badge ID, and trigger value."
      parameters:
        -
          in: query
          name: id
          description: 'integer The ID of the event to be retrieved.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'integer The ID of the event to be retrieved.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'Event 1'
                  eventType: total_module_completed
                  selectedBadgeId: 123
                  triggerValue: 5.6
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'Event 1'
                  eventType:
                    type: string
                    example: total_module_completed
                  selectedBadgeId:
                    type: integer
                    example: 123
                  triggerValue:
                    type: number
                    example: 5.6
      tags:
        - Gamification
      security: []
    put:
      summary: 'Update a specific gamification event.'
      operationId: updateASpecificGamificationEvent
      description: "Updates the details of a gamification event by its ID, including\nthe event name, type, selected badge ID, and trigger value."
      parameters:
        -
          in: query
          name: name
          description: 'string The name of the Event.'
          example: '"Event 1"'
          required: true
          schema:
            type: string
            description: 'string The name of the Event.'
            example: '"Event 1"'
        -
          in: query
          name: eventType
          description: 'string The type of the Event.'
          example: '"total_module_completed"'
          required: true
          schema:
            type: string
            description: 'string The type of the Event.'
            example: '"total_module_completed"'
        -
          in: query
          name: selectedBadgeId
          description: 'The ID of the selected badge.'
          example: '123'
          required: true
          schema:
            type: string
            description: 'The ID of the selected badge.'
            example: '123'
        -
          in: query
          name: triggerValue
          description: 'interger The trigger value for the event.'
          example: '5.6'
          required: true
          schema:
            type: string
            description: 'interger The trigger value for the event.'
            example: '5.6'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Event updated successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Event updated successfully'
      tags:
        - Gamification
      security: []
  '/api/gamification_event/delete/{id}':
    post:
      summary: 'Delete a specific gamification event.'
      operationId: deleteASpecificGamificationEvent
      description: "Deletes a gamification event by its ID, but only if no badge has been assigned\nto a user for that event. If a badge has been assigned, the event cannot be\ndeleted."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Event cannot be deleted as a badge has been assigned to user for this event'
                properties:
                  message:
                    type: string
                    example: 'Event cannot be deleted as a badge has been assigned to user for this event'
      tags:
        - Gamification
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'integer The ID of the event to be deleted.'
        example: '1'
        required: true
        schema:
          type: string
  /api/siteLanguages:
    get:
      summary: 'Get site languages'
      operationId: getSiteLanguages
      description: 'Get list of all supported languages with their display name.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n     [\n         {\n             \"db_value\": \"en\",\n             \"display_value\": \"English (US)\"\n         },\n         {\n             \"db_value\": \"es\",\n             \"display_value\": \"Spanish\"\n         },\n         {\n             \"db_value\": \"en-custom\",\n             \"display_value\": \"Custom English\"\n         },\n         {\n             \"db_value\": \"fr\",\n             \"display_value\": \"French\"\n         },\n         {\n             \"db_value\": \"gr\",\n             \"display_value\": \"German\"\n         }\n     ]\n}"
      tags:
        - 'General Settings'
      security: []
  /api/settings/emails/general:
    get:
      summary: 'Get General Email Settings'
      operationId: getGeneralEmailSettings
      description: 'Retrieves the details of the general email settings.'
      parameters:
        -
          in: query
          name: portalId
          description: 'Portal ID.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'Portal ID.'
            example: 1
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  fromName: 'Academy of Mine'
                  fromEmail: dev@academyofmine.com
                  replyToEmail: no-reply@academyofmine.com
                  templateDesign: default
                  headerLogo: Default
                  customHeaderLogoURL: null
                  headerBgColor: '#6b15b6'
                  bgColor: '#ffffff'
                  bodyBgColor: '#f6f9fc'
                  bodyTextColor: '#1b1e24'
                properties:
                  fromName:
                    type: string
                    example: 'Academy of Mine'
                  fromEmail:
                    type: string
                    example: dev@academyofmine.com
                  replyToEmail:
                    type: string
                    example: no-reply@academyofmine.com
                  templateDesign:
                    type: string
                    example: default
                  headerLogo:
                    type: string
                    example: Default
                  customHeaderLogoURL:
                    type: string
                    example: null
                  headerBgColor:
                    type: string
                    example: '#6b15b6'
                  bgColor:
                    type: string
                    example: '#ffffff'
                  bodyBgColor:
                    type: string
                    example: '#f6f9fc'
                  bodyTextColor:
                    type: string
                    example: '#1b1e24'
      tags:
        - 'General Settings'
      security: []
    put:
      summary: 'Update General Email Settings'
      operationId: updateGeneralEmailSettings
      description: 'To update the general email settings with updated values, you need to use this request. (See parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - 'General Settings'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                fromName:
                  type: string
                  description: 'From name for the email.'
                  example: 'Academy of Mine'
                fromEmail:
                  type: string
                  description: 'From email address for the email.'
                  example: dev@academyofmine.com
                replyToEmail:
                  type: string
                  description: 'Reply to email address for the email.'
                  example: no-reply@academyofmine.com
                templateDesign:
                  type: string
                  description: 'Template design for the email.'
                  example: default
                headerLogo:
                  type: string
                  description: 'Header logo for the email.'
                  example: Default
                customHeaderLogoURL:
                  type: string
                  description: 'Custom header logo URL for the email.'
                  example: 'null'
                headerBgColor:
                  type: string
                  description: 'Header background color for the email.'
                  example: '#6b15b6'
                bgColor:
                  type: string
                  description: 'Background color for the email.'
                  example: '#ffffff'
                bodyBgColor:
                  type: string
                  description: 'Body background color for the email.'
                  example: '#f6f9fc'
                bodyTextColor:
                  type: string
                  description: 'Body text color for the email.'
                  example: '#1b1e24'
                footerText:
                  type: string
                  description: 'Footer text for the email.'
                  example: 'Copyright &copy; Your Company Name - All rights reserved.'
                logoBgColor:
                  type: string
                  description: 'Logo background color for the email.'
                  example: '#1b1e24'
              required:
                - fromName
                - fromEmail
                - replyToEmail
                - templateDesign
                - headerLogo
                - customHeaderLogoURL
                - headerBgColor
                - bgColor
                - bodyBgColor
                - bodyTextColor
                - footerText
                - logoBgColor
      security: []
  /api/settings/edit-template:
    put:
      summary: 'Update email format for given type'
      operationId: updateEmailFormatForGivenType
      description: 'This api is used to update the email format of given type'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Template Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Template Updated Successfully'
      tags:
        - 'General Settings'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                type:
                  type: string
                  description: 'Type of email.'
                  example: upcoming_webinar
                portalId:
                  type: integer
                  description: 'Portal ID'
                  example: 11
                area:
                  type: string
                  description: 'Area of email.'
                  example: 'Course, Class'
                subject:
                  type: string
                  description: 'Subject of email.'
                  example: 'Your Upcoming Webinar'
                recipients:
                  type: string
                  description: 'Recipients of email.'
                  example: User
                heading:
                  type: string
                  description: 'Heading of email.'
                  example: 'Upcoming Webinar'
                content:
                  type: string
                  description: 'Content of email.'
                  example: 'This is a test email'
                enabled:
                  type: integer
                  description: 'Is email enabled?'
                  example: 1
                admin_enabled:
                  type: integer
                  description: 'Is email enabled for admin?'
                  example: 1
                hours:
                  type: integer
                  description: 'Number of hours.'
                  example: 24
                days:
                  type: integer
                  description: 'Number of days.'
                  example: 7
                interval:
                  type: string
                  description: 'Interval of reminder.'
                  example: days
                frequency:
                  type: string
                  description: 'Frequency of reminder.'
                  example: '1'
                enable_coupon:
                  type: integer
                  description: 'Is coupon enabled?'
                  example: 1
                coupon:
                  type: integer
                  description: 'Coupon ID.'
                  example: 1
              required:
                - type
                - portalId
                - area
                - subject
                - recipients
                - heading
                - content
                - enabled
                - admin_enabled
                - hours
                - days
                - interval
                - frequency
                - enable_coupon
                - coupon
      security: []
  /api/settings/get-template:
    get:
      summary: 'Get Email Format'
      operationId: getEmailFormat
      description: 'Retrieves the details of the email formats.'
      parameters:
        -
          in: query
          name: portalId
          description: ''
          example: 1
          required: true
          schema:
            type: integer
            description: ''
            example: 1
        -
          in: query
          name: type
          description: 'Array of email types.'
          example:
            - new_account_creation
            - new_account_creation_others
          required: true
          schema:
            type: array
            description: 'Array of email types.'
            example:
              - new_account_creation
              - new_account_creation_others
            items:
              type: string
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: 'array of objects'
      tags:
        - 'General Settings'
      security: []
  /api/settings/general:
    get:
      summary: 'Get General Settings'
      operationId: getGeneralSettings
      description: 'Get the general settings of the site.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  siteTitle: 'Academy of mine'
                  adminEmail: dev@academyofmine.com
                  siteLanguage: en
                  timeZone: 'null'
                  dateFormat: 'M d, Y'
                  timeFormat: 'h:i A'
                  privateSite: 'no'
                  customTimeZone: tempora
                  homePage: '1'
                  productCatalogPage: 2
                  cartPage: 5
                  checkoutPage: '4'
                  termConditionPage: 3
                  termConditionText: 'I have read and agree to the website term.'
                  privacyPolicyPage: 2
                  privacyPolicyText: 'Your personal data will be used to process your order, support your experience throughout this website, and for other purposes described in our privacy policy.'
                properties:
                  siteTitle:
                    type: string
                    example: 'Academy of mine'
                  adminEmail:
                    type: string
                    example: dev@academyofmine.com
                  siteLanguage:
                    type: string
                    example: en
                  timeZone:
                    type: string
                    example: 'null'
                  dateFormat:
                    type: string
                    example: 'M d, Y'
                  timeFormat:
                    type: string
                    example: 'h:i A'
                  privateSite:
                    type: string
                    example: 'no'
                  customTimeZone:
                    type: string
                    example: tempora
                  homePage:
                    type: string
                    example: '1'
                  productCatalogPage:
                    type: integer
                    example: 2
                  cartPage:
                    type: integer
                    example: 5
                  checkoutPage:
                    type: string
                    example: '4'
                  termConditionPage:
                    type: integer
                    example: 3
                  termConditionText:
                    type: string
                    example: 'I have read and agree to the website term.'
                  privacyPolicyPage:
                    type: integer
                    example: 2
                  privacyPolicyText:
                    type: string
                    example: 'Your personal data will be used to process your order, support your experience throughout this website, and for other purposes described in our privacy policy.'
      tags:
        - 'General Settings'
      security: []
    post:
      summary: 'Update General Settings'
      operationId: updateGeneralSettings
      description: 'Update the general settings of the site with provided values in the request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                  type: success
                  title: Success
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
                  type:
                    type: string
                    example: success
                  title:
                    type: string
                    example: Success
      tags:
        - 'General Settings'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                siteTitle:
                  type: string
                  description: 'Site title of the website.'
                  example: totam
                adminEmail:
                  type: string
                  description: 'Admin email of the website.'
                  example: uupton@example.com
                siteLanguage:
                  type: string
                  description: 'Language of the site.'
                  example: facilis
                timeZone:
                  type: string
                  description: 'Timezone of the site.'
                  example: Asia/Tashkent
                dateFormat:
                  type: string
                  description: 'Date format of the site.'
                  example: ullam
                timeFormat:
                  type: string
                  description: 'Time format of the site.'
                  example: soluta
                privateSite:
                  type: string
                  description: 'Is the site private or not.'
                  example: consequatur
                customTimeZone:
                  type: string
                  description: 'Custom timezone for site.'
                  example: '"America/New_York"'
                homePage:
                  type: integer
                  description: 'Homepage for site(page Id).'
                  example: 1
                cartPage:
                  type: integer
                  description: 'Cart page for site(page Id).'
                  example: 1
                checkoutPage:
                  type: integer
                  description: 'Checkout page for site(page Id).'
                  example: 6
                termConditionPage:
                  type: integer
                  description: 'Term and Condition page for the site(page Id).'
                  example: 11
                termConditionText:
                  type: string
                  description: 'Term and Condition Text of the site.'
                  example: voluptas
                privacyPolicyPage:
                  type: integer
                  description: 'Privacy Policy page for the site(page Id).'
                  example: 7
                privacyPolicyText:
                  type: string
                  description: 'Privacy Policy Text of the site.'
                  example: mollitia
                cookieTitle:
                  type: string
                  description: 'Cookie Title of the site.'
                  example: rem
                cookieAccept:
                  type: string
                  description: 'Cookie Accept Button of the site.'
                  example: sapiente
                cookieReject:
                  type: string
                  description: 'Cookie Reject Button of the site.'
                  example: reiciendis
                cookieMessage:
                  type: string
                  description: 'Cookie Message of the site.'
                  example: pariatur
                thankyouPage:
                  type: integer
                  description: 'Thank you page for the site(page Id).'
                  example: 5
                cookieEnable:
                  type: integer
                  description: 'Is the cookie enable or not.'
                  example: 10
                googleRecaptchaEnable:
                  type: integer
                  description: 'Is the google recaptcha enable or not.'
                  example: 14
                googleRecaptchaSiteKey:
                  type: string
                  description: 'Google recaptcha site key.'
                  example: odit
                googleRecaptchaSecretKey:
                  type: string
                  description: 'Google recaptcha secret key.'
                  example: commodi
                blockedEmailsDomains:
                  type: string
                  description: 'Blocked emails domains.'
                  example: quia
                anyOneCanRegister:
                  type: integer
                  description: 'Is the anyone can register or not.'
                  example: 8
                learnerDashboard:
                  type: string
                  description: 'Learner dashboard page/menu id.'
                  example: aspernatur
                customCatalogPageurl:
                  type: string
                  description: 'Custom catalog page url.'
                  example: 'http://goodwin.com/aut-odit-incidunt-ipsam-quo-molestiae-aut'
              required:
                - siteTitle
                - adminEmail
                - siteLanguage
                - timeZone
                - dateFormat
                - timeFormat
                - privateSite
                - customTimeZone
                - homePage
                - cartPage
                - checkoutPage
                - termConditionPage
                - termConditionText
                - privacyPolicyPage
                - privacyPolicyText
                - cookieTitle
                - cookieAccept
                - cookieReject
                - cookieMessage
                - thankyouPage
                - cookieEnable
                - googleRecaptchaEnable
                - googleRecaptchaSiteKey
                - googleRecaptchaSecretKey
                - blockedEmailsDomains
                - anyOneCanRegister
                - learnerDashboard
                - customCatalogPageurl
      security: []
  /api/settings/customTimezone:
    get:
      summary: 'Get a list of custom timezones.'
      operationId: getAListOfCustomTimezones
      description: "Returns all available PHP timezones except a predefined custom list.\nUseful for showing only non-default timezones to users or filtering out common ones."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: string
                example:
                  - Africa/Abidjan
                  - Africa/Accra
                  - Africa/Addis_Ababa
                  - Africa/Algiers
                  - Africa/Asmara
                  - Africa/Bamako
      tags:
        - 'General Settings'
      security: []
  /api/settings/branding:
    get:
      summary: 'Retrieve branding settings'
      operationId: retrieveBrandingSettings
      description: 'Retrieves the details of the brand settings. Helps in fetching items of the brand settings, items like primary color, body color, logo footer text(See Response)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  brandColors:
                    primaryColor: '#6b15b6'
                    bodyBgColor: '#f6f9fc'
                    bodyColor: '#1b1e24'
                  logo: ''
                  logoMini: ''
                  topBarEmail: info@your-company.com
                  topBarPhone: +1-202-555-0189
                  footerText: 'Copyright &copy; Your Company Name - All rights reserved.'
                  headerBgColor: '#6b15b6'
                  menuTextColor: '#6b15b6'
                  favicon: favicon.ico
                  robotsTxt: 'User-agent: *'
                  hideSearchEngineVisibility: 'no'
                  learnerDashboard: dashboard
                properties:
                  brandColors:
                    type: object
                    properties:
                      primaryColor:
                        type: string
                        example: '#6b15b6'
                      bodyBgColor:
                        type: string
                        example: '#f6f9fc'
                      bodyColor:
                        type: string
                        example: '#1b1e24'
                  logo:
                    type: string
                    example: ''
                  logoMini:
                    type: string
                    example: ''
                  topBarEmail:
                    type: string
                    example: info@your-company.com
                  topBarPhone:
                    type: string
                    example: +1-202-555-0189
                  footerText:
                    type: string
                    example: 'Copyright &copy; Your Company Name - All rights reserved.'
                  headerBgColor:
                    type: string
                    example: '#6b15b6'
                  menuTextColor:
                    type: string
                    example: '#6b15b6'
                  favicon:
                    type: string
                    example: favicon.ico
                  robotsTxt:
                    type: string
                    example: 'User-agent: *'
                  hideSearchEngineVisibility:
                    type: string
                    example: 'no'
                  learnerDashboard:
                    type: string
                    example: dashboard
      tags:
        - 'General Settings'
      security: []
    put:
      summary: 'Set branding settings'
      operationId: setBrandingSettings
      description: 'Set the branding settings of the site.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Branding Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Branding Settings Updated'
      tags:
        - 'General Settings'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                brandColors:
                  type: object
                  description: 'Brand colors object.'
                  example: []
                  properties: {  }
                logo:
                  type: string
                  description: 'Logo of the site.'
                  example: '"logo.png"'
                logoMini:
                  type: string
                  description: 'Mini logo of the site.'
                  example: '"mini-logo.png"'
                topBarEmail:
                  type: string
                  description: 'Top bar email of the site.'
                  example: '"info@your-company.com"'
                topBarPhone:
                  type: string
                  description: 'Top bar phone of the site.'
                  example: '"+1 123 456 7890"'
                menuTextColor:
                  type: string
                  description: 'Menu text color of the site.'
                  example: '"#6b15b6"'
                footerText:
                  type: string
                  description: 'Footer text of the site.'
                  example: '"Copyright &copy; Your Company Name - All rights reserved."'
                headerBgColor:
                  type: string
                  description: 'Header background color of the site.'
                  example: '"#6b15b6"'
                favicon:
                  type: string
                  description: 'Favicon of the site.'
                  example: '"favicon.ico"'
                robotsTxt:
                  type: string
                  description: 'Robots.txt of the site.'
                  example: '"User-agent: *"'
                hideSearchEngineVisibility:
                  type: string
                  description: 'Hide search engine visibility of the site.'
                  example: '"no"'
                shouldCompileTheme:
                  type: string
                  description: 'Should compile theme of the site.'
                  example: '"true"'
              required:
                - brandColors
                - logo
                - logoMini
                - topBarEmail
                - topBarPhone
                - menuTextColor
                - footerText
                - headerBgColor
                - favicon
                - robotsTxt
                - hideSearchEngineVisibility
                - shouldCompileTheme
      security: []
  /api/settings/customstyle:
    get:
      summary: 'Retrieves the custom CSS added in the platform.'
      operationId: retrievesTheCustomCSSAddedInThePlatform
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n \"custom_css\": \".aom-button {\n    background-color: #fff;\n }\"\n}"
      tags:
        - 'General Settings'
      security: []
    put:
      summary: 'Set Custom Stylings'
      operationId: setCustomStylings
      description: 'Updates the custom CSS added in the platform.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Custom Styling Saved Successfully'
                properties:
                  message:
                    type: string
                    example: 'Custom Styling Saved Successfully'
      tags:
        - 'General Settings'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                custom_css:
                  type: string
                  description: 'The custom CSS to be added in the platform.'
                  example: ".aom-button {\n  background-color: #fff;\n}"
              required:
                - custom_css
      security: []
  /api/settings/update-state:
    put:
      summary: 'Updates the status of the email if the selected area of the email format as enabled or not.'
      operationId: updatesTheStatusOfTheEmailIfTheSelectedAreaOfTheEmailFormatAsEnabledOrNot
      description: 'If disabled, the students will not get any email from this platform for selected email format area(account, lms, ecommerce, etc) and type (account creation, enrollments, etc)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Email State Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Email State Updated Successfully'
      tags:
        - 'General Settings'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                area:
                  type: string
                  description: 'The email format area.'
                  example: 'account, lms, ecommerce, etc'
                type:
                  type: string
                  description: 'The email type.'
                  example: 'new_account_creation, course_enrolled, etc'
                isEnabled:
                  type: boolean
                  description: 'The status of the email.'
                  example: true
                admin_enabled:
                  type: boolean
                  description: 'The status of the email for admins.'
                  example: true
                portalId:
                  type: integer
                  description: 'The portal id.'
                  example: 1
              required:
                - area
                - type
                - isEnabled
                - admin_enabled
                - portalId
      security: []
  /api/generic-search:
    post:
      summary: 'Searches for courses, users, products, and modules by name or email in the whole platform or in a specific portal.'
      operationId: searchesForCoursesUsersProductsAndModulesByNameOrEmailInTheWholePlatformOrInASpecificPortal
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  courses:
                    -
                      label: Course1
                      value: /dashboard/course/manage/1
                    -
                      label: Course2
                      value: /dashboard/course/manage/2
                  users:
                    -
                      label: 'John Doe (john.doe@example.com)'
                      value: /dashboard/user/edit/1
                    -
                      label: 'Jane Doe (jane.doe@example.com)'
                      value: /dashboard/user/edit/2
                  products:
                    -
                      label: Product1
                      value: /dashboard/product/edit/1
                    -
                      label: Product2
                      value: /dashboard/product/edit/2
                  modules:
                    -
                      label: Module1
                      value: /dashboard/modules/edit/1
                    -
                      label: Module2
                      value: /dashboard/modules/edit/2
                properties:
                  courses:
                    type: array
                    example:
                      -
                        label: Course1
                        value: /dashboard/course/manage/1
                      -
                        label: Course2
                        value: /dashboard/course/manage/2
                    items:
                      type: object
                      properties:
                        label:
                          type: string
                          example: Course1
                        value:
                          type: string
                          example: /dashboard/course/manage/1
                  users:
                    type: array
                    example:
                      -
                        label: 'John Doe (john.doe@example.com)'
                        value: /dashboard/user/edit/1
                      -
                        label: 'Jane Doe (jane.doe@example.com)'
                        value: /dashboard/user/edit/2
                    items:
                      type: object
                      properties:
                        label:
                          type: string
                          example: 'John Doe (john.doe@example.com)'
                        value:
                          type: string
                          example: /dashboard/user/edit/1
                  products:
                    type: array
                    example:
                      -
                        label: Product1
                        value: /dashboard/product/edit/1
                      -
                        label: Product2
                        value: /dashboard/product/edit/2
                    items:
                      type: object
                      properties:
                        label:
                          type: string
                          example: Product1
                        value:
                          type: string
                          example: /dashboard/product/edit/1
                  modules:
                    type: array
                    example:
                      -
                        label: Module1
                        value: /dashboard/modules/edit/1
                      -
                        label: Module2
                        value: /dashboard/modules/edit/2
                    items:
                      type: object
                      properties:
                        label:
                          type: string
                          example: Module1
                        value:
                          type: string
                          example: /dashboard/modules/edit/1
      tags:
        - 'General Settings'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                search_term:
                  type: string
                  description: 'The keyword to search.'
                  example: '"John Doe"'
                portalId:
                  type: integer
                  description: 'The portal ID to search in a specific portal. Use -1 to search in the whole platform.'
                  example: 5
              required:
                - search_term
                - portalId
      security: []
  /api/settings/gamification:
    get:
      summary: 'Retrieves the status of the gamification feature.'
      operationId: retrievesTheStatusOfTheGamificationFeature
      description: 'Retrieves the status of gamification feature. Returns a boolean value if the feature is enabled or disabled.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_enabled: true
                properties:
                  is_enabled:
                    type: boolean
                    example: true
      tags:
        - 'General Settings'
      security: []
    put:
      summary: 'Update Gamification Settings'
      operationId: updateGamificationSettings
      description: "Updates the gamification settings based on the provided request parameters.\nToggles the gamification feature on or off."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                  type: success
                  title: Success
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
                  type:
                    type: string
                    example: success
                  title:
                    type: string
                    example: Success
      tags:
        - 'General Settings'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                is_enabled:
                  type: boolean
                  description: 'The status to enable or disable gamification.'
                  example: true
              required:
                - is_enabled
      security: []
  /api/integrations/hubspot/eventLookup:
    get:
      summary: 'Hubspot Event Lookup'
      operationId: hubspotEventLookup
      description: "Retrieves all the events for the hubspot actions.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: new_account_created
                    display_value: 'New Account Created'
                    crud_op: Create
                    hubspot_crud: "[{'db_value' => 'hubspot_contact', 'display_value'=> 'Create New HubSpot Contact'}]"
                  -
                    db_value: 'Account Updated'
                    display_value: 'Account Updated'
                    crud_op: Update
                    hubspot_crud: "[['db_value' => 'hubspot_contact', 'display_value'=> 'Update HubSpot Contact']]"
                  -
                    db_value: course_enrolled
                    display_value: 'Enrolled in a course'
                    crud_op: Update
                    hubspot_crud: "[['db_value' => 'hubspot_contact', 'display_value'=> 'Update Course Status in HubSpot Contact']]"
                  -
                    db_value: course_completed
                    display_value: 'Course Completed'
                    crud_op: Update
                    hubspot_crud: "[['db_value' => 'hubspot_contact', 'display_value'=> 'Update Course Status to complete in  HubSpot Contact']]"
                  -
                    db_value: course_started
                    display_value: 'Course Started'
                    crud_op: Update
                    hubspot_crud: "[['db_value' => 'hubspot_contact', 'display_value'=> 'Update Course Status to in progress in  HubSpot Contact']]"
                  -
                    db_value: course_progress
                    display_value: 'Course Progress Tracking'
                    crud_op: Update
                    hubspot_crud: "[['db_value' => 'hubspot_deal', 'display_value'=> 'Update Course Progress in HubSpot Deal']]"
                  -
                    db_value: course_expired
                    display_value: 'Course Expired'
                    crud_op: Update
                    hubspot_crud: "[['db_value' => 'hubspot_contact', 'display_value'=> 'HubSpot Contact']]"
      tags:
        - 'Hubspot Integration'
      security: []
  /api/integrations/hubspot/fieldLookup:
    get:
      summary: 'Field Lookup'
      operationId: fieldLookup
      description: "Retrieves all the fields for the hubspot.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    lms_fields:
                      -
                        db_value: email
                      -
                        db_value: last_name
                      -
                        db_value: first_name
                      -
                        db_value: last_login_ip
                      -
                        db_value: is_disabled
                  -
                    hubspot_fields:
                      -
                        db_value: email
                      -
                        db_value: lastname
                      -
                        db_value: firstname
                  -
                    courses:
                      -
                        id: 1
                        name: 'Course 1'
                      -
                        id: 2
                        name: 'Course 2'
      tags:
        - 'Hubspot Integration'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                type:
                  type: string
                  description: 'Type to get the data, it can either be contact or deal.'
                  example: ut
              required:
                - type
      security: []
  /api/hubspot/action/create:
    post:
      summary: 'Create Hubspot Action'
      operationId: createHubspotAction
      description: 'Creates a Hubspot action based on the provided parameters.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Action created Successfully'
                properties:
                  message:
                    type: string
                    example: 'Action created Successfully'
      tags:
        - 'Hubspot Integration'
      security: []
    parameters:
      -
        in: path
        name: event
        description: 'The event of the Hubspot action.'
        example: 0
        required: true
        schema:
          type: integer
      -
        in: path
        name: action
        description: 'The action of the Hubspot action.'
        example: create
        required: true
        schema:
          type: string
      -
        in: path
        name: object
        description: 'The object of the Hubspot action.'
        example: 'Hubspot Contact'
        required: true
        schema:
          type: string
  /api/hubspot/mapping/save:
    post:
      summary: 'Save Hubspot Mapping'
      operationId: saveHubspotMapping
      description: 'Saves the mapping of hubspot mapping. Helps in saving hubspot mapping using its type. (See Parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: true
                  message: 'Mapping saved Successfully'
                properties:
                  is_success:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Mapping saved Successfully'
      tags:
        - 'Hubspot Integration'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                type:
                  type: required
                  description: 'Type of the hupspot mapping you want to save the details of.'
                  example: hubspot_contact
                dealIdentifierObjectAndProperties:
                  type: array
                  description: 'Deal identifier object and properties. (See parameters)'
                  example:
                    - blanditiis
                  items:
                    type: string
                courseFieldProperties:
                  type: array
                  description: 'Course field properties. (See parameters)'
                  example:
                    - reiciendis
                  items:
                    type: string
                userFieldProperties:
                  type: array
                  description: 'User field properties. (See parameters)'
                  example:
                    - voluptatibus
                  items:
                    type: string
                conditionMappingData:
                  type: array
                  description: 'Array of condition mapping data.'
                  example:
                    -
                      id: 1
                      conditionOperator: AND
                      conditionValue: hasdeal
                      conditionType: CONTACT
                      conditionOperatorValue: CONTAINS
                    -
                      id: 2
                      conditionOperator: OR
                      conditionValue: hasdeal
                      conditionType: CONTACT
                      conditionOperatorValue: CONTAINS
                  items:
                    type: string
              required:
                - dealIdentifierObjectAndProperties
                - courseFieldProperties
                - userFieldProperties
                - conditionMappingData
      security: []
  /api/hubspot/mappings:
    get:
      summary: 'Retrieve Hubspot Mapping'
      operationId: retrieveHubspotMapping
      description: 'Retrieves the details of the hubspot mapping. Helps in fetching hubspot mapping using its type. (See Parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  type: hubspot_condition
                  conditions: []
                properties:
                  type:
                    type: string
                    example: hubspot_condition
                  conditions:
                    type: array
                    example: []
      tags:
        - 'Hubspot Integration'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                type:
                  type: required
                  description: 'Type of the hupspot mapping you want to fetch the details of.'
                  example: hubspot_contact
      security: []
  /api/hubspots:
    get:
      summary: 'Retrieves HubSpot integrations in a tabular format with pagination.'
      operationId: retrievesHubSpotIntegrationsInATabularFormatWithPagination
      description: "This function handles requests for retrieving a list of HubSpot integration events\nin a paginated tabular format. It allows filtering by events and ordering by specified\ncolumns. The results include detailed information about each event, such as the event\nand object display values, action, author, and timestamp."
      parameters:
        -
          in: query
          name: order_by
          description: 'JSON object for ordering items based on specified columns.'
          example: '{"colName": "created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'JSON object for ordering items based on specified columns.'
            example: '{"colName": "created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'JSON object for filtering items by events.'
          example: 0
          required: false
          schema:
            type: integer
            description: 'JSON object for filtering items by events.'
            example: 0
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 20
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      event: course_enrolled
                      event_display_value: 'Enrolled in a Course'
                      object: hubspot_contact
                      object_display_value: 'HubSpot Contact'
                      action: created
                      author: 'John Doe'
                      created_at: '2021-01-01 12:00:00'
                properties:
                  recordsTotal:
                    type: integer
                    example: 20
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        event: course_enrolled
                        event_display_value: 'Enrolled in a Course'
                        object: hubspot_contact
                        object_display_value: 'HubSpot Contact'
                        action: created
                        author: 'John Doe'
                        created_at: '2021-01-01 12:00:00'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        event:
                          type: string
                          example: course_enrolled
                        event_display_value:
                          type: string
                          example: 'Enrolled in a Course'
                        object:
                          type: string
                          example: hubspot_contact
                        object_display_value:
                          type: string
                          example: 'HubSpot Contact'
                        action:
                          type: string
                          example: created
                        author:
                          type: string
                          example: 'John Doe'
                        created_at:
                          type: string
                          example: '2021-01-01 12:00:00'
      tags:
        - 'Hubspot Integration'
      security: []
  '/api/hubspot/{id}':
    put:
      summary: 'Update Hubspot Action'
      operationId: updateHubspotAction
      description: 'Updates a Hubspot action based on the provided ID.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Hubspot updated successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Hubspot updated successfully'
      tags:
        - 'Hubspot Integration'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                event:
                  type: required
                  description: 'The event of the Hubspot action.'
                  example: 'New Account Created'
                action:
                  type: required
                  description: 'The action of the Hubspot action.'
                  example: create
                object:
                  type: required
                  description: 'The object of the Hubspot action.'
                  example: 'Hubspot Deal'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the Hubspot action to be updated.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/hubspot/action/delete/{id}':
    post:
      summary: 'Delete Hubspot Action'
      operationId: deleteHubspotAction
      description: 'Deletes a Hubspot action based on the provided ID.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Hubspot deleted successfully'
                properties:
                  message:
                    type: string
                    example: 'Hubspot deleted successfully'
      tags:
        - 'Hubspot Integration'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the Hubspot action to be deleted.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/hubspot/logs/{id}':
    get:
      summary: 'Hubspot Log Tabular List'
      operationId: hubspotLogTabularList
      description: 'Returns all the Hubspot log in a tabular list format in paginated mode.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      event: 'New Account Created'
                      data: []
                      status: success
                      errorMessage: ''
                      created_at: 'Aug 03, 2020 09:56 AM'
                      showData: false
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        event: 'New Account Created'
                        data: []
                        status: success
                        errorMessage: ''
                        created_at: 'Aug 03, 2020 09:56 AM'
                        showData: false
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        event:
                          type: string
                          example: 'New Account Created'
                        data:
                          type: array
                          example: []
                        status:
                          type: string
                          example: success
                        errorMessage:
                          type: string
                          example: ''
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        showData:
                          type: boolean
                          example: false
      tags:
        - 'Hubspot Integration'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the Hubspot action.'
        example: '50'
        required: true
        schema:
          type: string
  /api/hubspot/conditionLookup:
    get:
      summary: 'Conditions Lookup'
      operationId: conditionsLookup
      description: "Retrieves all the conditions for Hubspot.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: equal_to
                    display_value: '='
                  -
                    db_value: not_equal_to
                    display_value: '!='
                  -
                    db_value: greater_than
                    display_value: '>'
                  -
                    db_value: less_than
                    display_value: '<'
      tags:
        - 'Hubspot Integration'
      security: []
  /api/hubspot/operatorsLookup:
    get:
      summary: 'Operator Lookup'
      operationId: operatorLookup
      description: "Retrieves all the operators for Hubspot.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: and
                    display_value: And
                  -
                    db_value: or
                    display_value: Or
      tags:
        - 'Hubspot Integration'
      security: []
  /api/hubspot/importUser:
    post:
      summary: 'Import users from HubSpot.'
      operationId: importUsersFromHubSpot
      description: "This endpoint is used to initiate a user import process from HubSpot. It saves the provided HubSpot conditions,\nupdates the import identifier for tracking, logs the import event, and dispatches a job to process the import in the background."
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  success: true
                  importId: 2
                  message: 'Hubspot import user sync executed and in running state. Refresh to know its status.'
                properties:
                  success:
                    type: boolean
                    example: true
                  importId:
                    type: integer
                    example: 2
                  message:
                    type: string
                    example: 'Hubspot import user sync executed and in running state. Refresh to know its status.'
      tags:
        - 'Hubspot Integration'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                hubspotConditions:
                  type: array
                  description: 'The conditions used to filter HubSpot users before import.'
                  example:
                    - totam
                  items:
                    type: string
              required:
                - hubspotConditions
      security: []
  /api/hubspot/import-user/status:
    get:
      summary: 'Get the status of the last HubSpot user import.'
      operationId: getTheStatusOfTheLastHubSpotUserImport
      description: "This endpoint is used to get the status of the last HubSpot user import. It returns the status of the import, which can be either 'success', 'failed', or 'queue'.\nIf the import is still in queue, it means that the import has been initiated but has not completed yet. If the import has failed, it means that there was an error during the import process.\nIf the import was successful, it means that the import has completed without any errors."
      parameters:
        -
          in: query
          name: importId
          description: 'The identifier of the import job. If not provided, it defaults to the latest import job.'
          example: et
          required: false
          schema:
            type: string
            description: 'The identifier of the import job. If not provided, it defaults to the latest import job.'
            example: et
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  lastImportedDate: '22-Jan-2020 12:00 AM'
                  status: success
                properties:
                  lastImportedDate:
                    type: string
                    example: '22-Jan-2020 12:00 AM'
                  status:
                    type: string
                    example: success
      tags:
        - 'Hubspot Integration'
      security: []
  '/api/hubspot/importUserlogs/{id}':
    get:
      summary: 'Get Import User Logs'
      operationId: getImportUserLogs
      description: 'Returns all the Hubspot import user log in a tabular list format in paginated mode.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      importIdentifier: 1
                      event: import_users
                      importedData: '[]'
                      skippedData: ''
                      message: 'Import completed successfully'
                      status: success
                      display_status: Success
                      errorMessage: ''
                      created_at: 'Aug 03, 2020 09:56 AM'
                      showData: false
                      queueStatus: success
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        importIdentifier: 1
                        event: import_users
                        importedData: '[]'
                        skippedData: ''
                        message: 'Import completed successfully'
                        status: success
                        display_status: Success
                        errorMessage: ''
                        created_at: 'Aug 03, 2020 09:56 AM'
                        showData: false
                        queueStatus: success
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        importIdentifier:
                          type: integer
                          example: 1
                        event:
                          type: string
                          example: import_users
                        importedData:
                          type: string
                          example: '[]'
                        skippedData:
                          type: string
                          example: ''
                        message:
                          type: string
                          example: 'Import completed successfully'
                        status:
                          type: string
                          example: success
                        display_status:
                          type: string
                          example: Success
                        errorMessage:
                          type: string
                          example: ''
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        showData:
                          type: boolean
                          example: false
                        queueStatus:
                          type: string
                          example: success
      tags:
        - 'Hubspot Integration'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the Hubspot action.'
        example: '50'
        required: true
        schema:
          type: string
  /api/integrations/listing:
    get:
      summary: 'Get all integrations.'
      operationId: getAllIntegrations
      description: "Returns a list of all available integrations with their details such as name, identifier, logo, and status.\nThe timestamps are formatted based on the app's configured timezone, language, date, and time format."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: HubSpot
                    identifier: hubspot
                    description: 'CRM Integration with HubSpot'
                    logo_url: 'https://example.com/images/hubspot.png'
                    is_enabled: true
                    implementer_class: App\Integrations\Hubspot
                    created_by: 1
                    updated_by: 2
                    created_at: 'Apr 12, 2025 10:35 AM'
                    updated_at: 'Apr 12, 2025 11:40 AM'
      tags:
        - Integrations
      security: []
  '/api/integrations/settings/{id}':
    put:
      summary: 'Update Integration Settings'
      operationId: updateIntegrationSettings
      description: 'Updates the integration settings for a specified integration. Setting needs to be updated is mentioned in parameter. (See Parameter)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - Integrations
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
                  example: 5
                is_enabled:
                  type: boolean
                  description: 'Enable status of integration.'
                  example: true
                settings:
                  type: array
                  description: 'An associative array of settings to be updated.'
                  example:
                    - laborum
                  items:
                    type: string
              required:
                - is_enabled
                - settings
      security: []
    get:
      summary: 'Retrieve Integration Settings'
      operationId: retrieveIntegrationSettings
      description: 'Retrieves all the integration settings for a specified integration. Helps in mainting the data and enable status of the integration.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Google Analytics'
                  identifier: google-analytics
                  is_enabled: false
                  settings:
                    ga_code: '<script type="text/javascript">var a = 12;</script>'
                properties:
                  name:
                    type: string
                    example: 'Google Analytics'
                  identifier:
                    type: string
                    example: google-analytics
                  is_enabled:
                    type: boolean
                    example: false
                  settings:
                    type: object
                    properties:
                      ga_code:
                        type: string
                        example: '<script type="text/javascript">var a = 12;</script>'
      tags:
        - Integrations
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the integration.'
        example: '1'
        required: true
        schema:
          type: string
  /api/integrations/updateStatus:
    put:
      summary: 'Update the status of an integration'
      operationId: updateTheStatusOfAnIntegration
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Settings Updated'
                properties:
                  message:
                    type: string
                    example: 'Settings Updated'
      tags:
        - Integrations
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                status:
                  type: boolean
                  description: 'Enable status of integration.'
                  example: true
              required:
                - status
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the integration.'
        example: '1'
        required: true
        schema:
          type: string
  /api/integrations/webinar/lookup:
    get:
      summary: "Returns all the Integrations' Settings for a given Portal in a paginated list format."
      operationId: returnsAllTheIntegrationsSettingsForAGivenPortalInAPaginatedListFormat
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: '{"is_enabled":true,"name":"zoom"},{"is_enabled":true,"name":"goto_webinar"},{"is_enabled":true,"name":"goto_training"},{"is_enabled":true,"name":"ms_team_meet"}'
      tags:
        - Integrations
      security: []
    parameters:
      -
        in: path
        name: portalId
        description: 'ID of the portal you want to retrieve integrations settings of.'
        example: '2'
        required: true
        schema:
          type: string
  /api/shopify/product/lookup:
    post:
      summary: 'Retrieve Shopify Product List'
      operationId: retrieveShopifyProductList
      description: 'Return all the Shopify Product, you need to use this request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "[\n    \"productList\" => [\n        [\n            \"id\" => \"1234567890\",\n            \"title\" => \"Introduction to Continuing Education\"\n        ],\n        [\n            \"id\" => \"2345678901\",\n            \"title\" => \"Professional Training And Education\"\n        ]\n    ],\n    \"isShopifyEnabled\" => true\n]"
      tags:
        - Integrations
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                search_term:
                  type: string
                  description: 'Search term to search the product in Shopify.'
                  example: '"Introduction".'
              required:
                - search_term
      security: []
  /api/shopify/product/create:
    post:
      summary: 'Create a product in shopify with the price and title provided in request'
      operationId: createAProductInShopifyWithThePriceAndTitleProvidedInRequest
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "[\n    \"success\" => true,\n    \"message\" => \"Product created successfully\",\n    \"product_id\" => 123456,\n    \"product_title\" => \"Introduction to Continuing Education\"\n]"
      tags:
        - Integrations
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                title:
                  type: string
                  description: 'Title of the product.'
                  example: aut
                price:
                  type: integer
                  description: 'Price of the product.'
                  example: 7
              required:
                - title
                - price
      security: []
  /api/lti/addPlatform:
    post:
      summary: 'Add a new LTI platform'
      operationId: addANewLTIPlatform
      description: 'Add a new LTI platform and save its details in the database.'
      parameters:
        -
          in: query
          name: platformId
          description: 'The platform ID.'
          example: 'https://canvas.instructure.com'
          required: true
          schema:
            type: string
            description: 'The platform ID.'
            example: 'https://canvas.instructure.com'
        -
          in: query
          name: platformName
          description: 'The name of the platform.'
          example: Canvas
          required: true
          schema:
            type: string
            description: 'The name of the platform.'
            example: Canvas
        -
          in: query
          name: clientId
          description: 'The client ID of the platform.'
          example: '1234567890'
          required: true
          schema:
            type: string
            description: 'The client ID of the platform.'
            example: '1234567890'
        -
          in: query
          name: jwksUrl
          description: 'The JWKS URL of the platform.'
          example: 'https://canvas.instructure.com/api/lti/security/jwks'
          required: true
          schema:
            type: string
            description: 'The JWKS URL of the platform.'
            example: 'https://canvas.instructure.com/api/lti/security/jwks'
        -
          in: query
          name: accessTokenUrl
          description: 'The access token URL of the platform.'
          example: 'https://canvas.instructure.com/login/oauth2/token'
          required: true
          schema:
            type: string
            description: 'The access token URL of the platform.'
            example: 'https://canvas.instructure.com/login/oauth2/token'
        -
          in: query
          name: authEndPoint
          description: 'The authentication endpoint URL of the platform.'
          example: 'https://canvas.instructure.com/api/lti/authorize_redirect'
          required: true
          schema:
            type: string
            description: 'The authentication endpoint URL of the platform.'
            example: 'https://canvas.instructure.com/api/lti/authorize_redirect'
        -
          in: query
          name: roles
          description: 'The roles of the users.'
          example: '["Student", "Teacher"]'
          required: true
          schema:
            type: string
            description: 'The roles of the users.'
            example: '["Student", "Teacher"]'
        -
          in: query
          name: contentAccessible
          description: 'Whether the content is accessible or not.'
          example: 'true'
          required: true
          schema:
            type: string
            description: 'Whether the content is accessible or not.'
            example: 'true'
        -
          in: query
          name: teacherProvisioningMode
          description: 'The provisioning mode for the teacher.'
          example: '"New accounts only"'
          required: true
          schema:
            type: string
            description: 'The provisioning mode for the teacher.'
            example: '"New accounts only"'
        -
          in: query
          name: studentProvisioningMode
          description: 'The provisioning mode for the student.'
          example: '"New accounts only"'
          required: true
          schema:
            type: string
            description: 'The provisioning mode for the student.'
            example: '"New accounts only"'
        -
          in: query
          name: deploymentId
          description: 'The deployment ID of the platform.'
          example: '1234567890'
          required: true
          schema:
            type: string
            description: 'The deployment ID of the platform.'
            example: '1234567890'
        -
          in: query
          name: courses
          description: 'The courses associated with the platform.'
          example: '[{"id":1,"name":"Course 1","syncGrade":true},{"id":2,"name":"Course 2","syncGrade":false}]'
          required: true
          schema:
            type: string
            description: 'The courses associated with the platform.'
            example: '[{"id":1,"name":"Course 1","syncGrade":true},{"id":2,"name":"Course 2","syncGrade":false}]'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 4
                  message: 'Platform Added Successfully'
                properties:
                  id:
                    type: integer
                    example: 4
                  message:
                    type: string
                    example: 'Platform Added Successfully'
      tags:
        - 'LTI Integration API'
      security: []
  /api/lti/updatePlatform:
    post:
      summary: 'Update LtiPlatform'
      operationId: updateLtiPlatform
      description: 'Updates the LtiPlatform along with its deployment and contents'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Platform Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Platform Updated Successfully'
      tags:
        - 'LTI Integration API'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'The ID of the LtiPlatform.'
                  example: '1'
                platformId:
                  type: required
                  description: 'The ID of the platform.'
                  example: example.com
                platformName:
                  type: required
                  description: 'The name of the platform.'
                  example: Example
                clientId:
                  type: required
                  description: 'The client ID of the platform.'
                  example: '123456789'
                jwksUrl:
                  type: required
                  description: 'The JWKS url of the platform.'
                  example: 'https://example.com/jwks'
                accessTokenUrl:
                  type: required
                  description: 'The access token URL of the platform.'
                  example: 'https://example.com/token'
                authEndPoint:
                  type: required
                  description: 'The authorization endpoint of the platform.'
                  example: 'https://example.com/auth'
                deploymentId:
                  type: required
                  description: 'The deployment ID of the platform.'
                  example: '123456789'
                roles:
                  type: required
                  description: 'The roles of the platform.'
                  example: '["Instructor", "Student"]'
                contentAccessible:
                  type: required
                  description: 'The content accessible of the platform.'
                  example: All
                teacherProvisioningMode:
                  type: required
                  description: 'The teacher provisioning mode of the platform.'
                  example: 'New accounts only'
                studentProvisioningMode:
                  type: required
                  description: 'The student provisioning mode of the platform.'
                  example: 'Existing and new accounts'
                courses:
                  type: required
                  description: 'The courses of the platform.'
                  example: '[{"id":1,"syncGrade":true}]'
      security: []
  '/api/lti/getPlatform/{id}':
    get:
      summary: 'Get a LTI platform by id'
      operationId: getALTIPlatformById
      description: 'This endpoint return a LTI platform by id with all its associated data.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  platformName: Test
                  platformId: 'https://canvas.instructure.com'
                  clientId: '1234567890'
                  jwksUrl: 'https://canvas.instructure.com/api/lti/security/jwks'
                  authEndPoint: 'https://canvas.instructure.com/login/oauth2/auth'
                  accessTokenUrl: 'https://canvas.instructure.com/login/oauth2/token'
                  deploymentId: '1234567890'
                  contentAccessible: 1
                  teacherProvisioningMode: new
                  studentProvisioningMode: new
                  roles: []
                  courses:
                    -
                      id: 1
                      name: 'Course 1'
                      syncGrade: true
                  id: 1
                properties:
                  platformName:
                    type: string
                    example: Test
                  platformId:
                    type: string
                    example: 'https://canvas.instructure.com'
                  clientId:
                    type: string
                    example: '1234567890'
                  jwksUrl:
                    type: string
                    example: 'https://canvas.instructure.com/api/lti/security/jwks'
                  authEndPoint:
                    type: string
                    example: 'https://canvas.instructure.com/login/oauth2/auth'
                  accessTokenUrl:
                    type: string
                    example: 'https://canvas.instructure.com/login/oauth2/token'
                  deploymentId:
                    type: string
                    example: '1234567890'
                  contentAccessible:
                    type: integer
                    example: 1
                  teacherProvisioningMode:
                    type: string
                    example: new
                  studentProvisioningMode:
                    type: string
                    example: new
                  roles:
                    type: array
                    example: []
                  courses:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Course 1'
                        syncGrade: true
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Course 1'
                        syncGrade:
                          type: boolean
                          example: true
                  id:
                    type: integer
                    example: 1
      tags:
        - 'LTI Integration API'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The id of the LTI platform.'
        example: '1'
        required: true
        schema:
          type: string
  /api/lti/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the LtiPlatforms in a tabular list format with pagination mode.\nYou can apply filter using search_param via courseCategoryIds(course category ID), courseName or roleNames(user role)"
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on Course category ids, course name.'
          example: '{"courseCategoryIds":[],"courseName":"course 1"}'
          required: false
          schema:
            type: string
            description: 'for searching items based on Course category ids, course name.'
            example: '{"courseCategoryIds":[],"courseName":"course 1"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 4
                  recordsFiltered: 4
                  records:
                    -
                      id: 4
                      name: superadmin
                      displayName: 'Super Admin'
                      createdAt: 'Aug 06, 2020 07:20 AM'
                      lastLogin: '2 days ago'
                    -
                      id: 2
                      name: admin
                      displayName: Admin
                      createdAt: 'Aug 03, 2020 09:31 AM'
                      lastLogin: Never
                    -
                      id: 3
                      name: groupadmin
                      displayName: 'Group Admin'
                      createdAt: 'Aug 03, 2020 09:31 AM'
                      lastLogin: Never
                    -
                      id: 1
                      name: student
                      displayName: Student
                      createdAt: 'Aug 03, 2020 09:31 AM'
                      lastLogin: Never
                properties:
                  recordsTotal:
                    type: integer
                    example: 4
                  recordsFiltered:
                    type: integer
                    example: 4
                  records:
                    type: array
                    example:
                      -
                        id: 4
                        name: superadmin
                        displayName: 'Super Admin'
                        createdAt: 'Aug 06, 2020 07:20 AM'
                        lastLogin: '2 days ago'
                      -
                        id: 2
                        name: admin
                        displayName: Admin
                        createdAt: 'Aug 03, 2020 09:31 AM'
                        lastLogin: Never
                      -
                        id: 3
                        name: groupadmin
                        displayName: 'Group Admin'
                        createdAt: 'Aug 03, 2020 09:31 AM'
                        lastLogin: Never
                      -
                        id: 1
                        name: student
                        displayName: Student
                        createdAt: 'Aug 03, 2020 09:31 AM'
                        lastLogin: Never
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 4
                        name:
                          type: string
                          example: superadmin
                        displayName:
                          type: string
                          example: 'Super Admin'
                        createdAt:
                          type: string
                          example: 'Aug 06, 2020 07:20 AM'
                        lastLogin:
                          type: string
                          example: '2 days ago'
      tags:
        - 'LTI Integration API'
      security: []
  /api/lti/deletePlatform:
    post:
      summary: 'Delete an LTI platform'
      operationId: deleteAnLTIPlatform
      description: 'Deletes the LTI platform along with its associated deployments and registrations from the database.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Platform deleted Successfully'
                properties:
                  message:
                    type: string
                    example: 'Platform deleted Successfully'
      tags:
        - 'LTI Integration API'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                deleteId:
                  type: required
                  description: 'The ID of the LTI platform to be deleted.'
                  example: '1'
      security: []
  /api/leaderboard/tabularlist:
    get:
      summary: 'Leaderboard Tier Tabular List'
      operationId: leaderboardTierTabularList
      description: 'Retrieves all the leaderboard tiers in a tabular list format.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  records:
                    -
                      id: 1
                      name: Bronze
                      lowerLimit: 0
                      upperLimit: 100
                    -
                      id: 2
                      name: Silver
                      lowerLimit: 101
                      upperLimit: 200
                    -
                      id: 3
                      name: Gold
                      lowerLimit: 201
                      upperLimit: 300
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: Bronze
                        lowerLimit: 0
                        upperLimit: 100
                      -
                        id: 2
                        name: Silver
                        lowerLimit: 101
                        upperLimit: 200
                      -
                        id: 3
                        name: Gold
                        lowerLimit: 201
                        upperLimit: 300
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: Bronze
                        lowerLimit:
                          type: integer
                          example: 0
                        upperLimit:
                          type: integer
                          example: 100
      tags:
        - Leaderboard
      security: []
  /api/leaderboard/create:
    post:
      summary: 'Create a new Tier'
      operationId: createANewTier
      description: 'Create a new Tier with `name`, `lowerLimit` and `upperLimit`.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Tier created successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Tier created successfully'
      tags:
        - Leaderboard
      security: []
    parameters:
      -
        in: path
        name: name
        description: 'The name of the Tier.'
        example: 'Level 1'
        required: true
        schema:
          type: string
      -
        in: path
        name: lowerLimit
        description: 'The lower limit of the Tier.'
        example: '1'
        required: true
        schema:
          type: string
      -
        in: path
        name: upperLimit
        description: 'The upper limit of the Tier.'
        example: '10'
        required: true
        schema:
          type: string
  '/api/leaderboard/{id}':
    get:
      summary: 'Get a Tier'
      operationId: getATier
      description: 'Get a Tier with `id`.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'Level 1'
                  lowerLimit: 1
                  upperLimit: 10
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'Level 1'
                  lowerLimit:
                    type: integer
                    example: 1
                  upperLimit:
                    type: integer
                    example: 10
      tags:
        - Leaderboard
      security: []
    put:
      summary: 'Update a Tier'
      operationId: updateATier
      description: 'Update a Tier with `id`, `name`, `lowerLimit` and `upperLimit`.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Tier updated successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Tier updated successfully'
      tags:
        - Leaderboard
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The id of the Tier.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/leaderboard/delete/{id}':
    post:
      summary: 'Delete a Tier'
      operationId: deleteATier
      description: 'Delete a Tier with `id`.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Tier deleted Succesfully.'
                  success: true
                properties:
                  message:
                    type: string
                    example: 'Tier deleted Succesfully.'
                  success:
                    type: boolean
                    example: true
      tags:
        - Leaderboard
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The id of the Tier.'
        example: '1'
        required: true
        schema:
          type: string
  /api/learning-paths/tabularlist:
    get:
      summary: 'Learning Path Tabular List'
      operationId: learningPathTabularList
      description: "Retrieves all the learning paths in a tabular list format in paginated mode.\nYou can apply filter using search_param via name(learning path name)."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'For searching items based on field names.'
          example: '{"name":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on field names.'
            example: '{"name":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      name: 'Test Learning Path'
                      status: PUBLISHED
                      display_status: PUBLISHED
                      created_at: 'Aug 03, 2020 09:31 AM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Test Learning Path'
                        status: PUBLISHED
                        display_status: PUBLISHED
                        created_at: 'Aug 03, 2020 09:31 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Test Learning Path'
                        status:
                          type: string
                          example: PUBLISHED
                        display_status:
                          type: string
                          example: PUBLISHED
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:31 AM'
      tags:
        - 'Learning Paths'
      security: []
  /api/learning-path/create:
    post:
      summary: 'Create Learning Path'
      operationId: createLearningPath
      description: 'Creates a new learning path with courses, certificates, prerequisites and categories.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Learning Path was successfully created'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Learning Path was successfully created'
      tags:
        - 'Learning Paths'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the learning path.'
                  example: 'Learning Path 1'
                instructions:
                  type: string
                  description: 'Instruction for the learning path.'
                  example: 'Some Instruction'
                featuredImageUrl:
                  type: string
                  description: 'Image for the learning path.'
                  example: img_path
                credits:
                  type: integer
                  description: 'Credit after learning path completion, used in certificates.'
                  example: 70
                status:
                  type: string
                  description: 'learning path is in Draft or Publish mode. Status options: draft or publish.'
                  example: publish
                certificates:
                  type: array
                  description: 'Certificates attached to this learning path.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
                prerequisites:
                  type: array
                  description: 'Prerequisites courses of the learning path.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
                courses:
                  type: array
                  description: 'All courses you want to attach to this learning path. Minimum 2 courses are required'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                categories:
                  type: array
                  description: 'Categories for this learning path.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
              required:
                - name
                - status
                - courses
      security: []
  '/api/learning-path/{id}':
    get:
      summary: 'Get Learning Path Details'
      operationId: getLearningPathDetails
      description: 'Retrieves all the details of the specified learning path.'
      parameters:
        -
          in: query
          name: id
          description: 'ID of the learning path.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the learning path.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'Test Learning Path'
                  slug: test-learning-path
                  status: DRAFT
                  instructions: 'Some Instruction'
                  featuredImageUrl: img_path
                  credits: 70
                  certificates:
                    - 1
                  accredible_group_id:
                    - 1
                  courses:
                    -
                      label: 'Course 1'
                      value: 1
                    -
                      label: 'Course 2'
                      value: 2
                  prerequisites:
                    '1': true
                    '2': false
                  categories:
                    - 1
                    - 2
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'Test Learning Path'
                  slug:
                    type: string
                    example: test-learning-path
                  status:
                    type: string
                    example: DRAFT
                  instructions:
                    type: string
                    example: 'Some Instruction'
                  featuredImageUrl:
                    type: string
                    example: img_path
                  credits:
                    type: integer
                    example: 70
                  certificates:
                    type: array
                    example:
                      - 1
                    items:
                      type: integer
                  accredible_group_id:
                    type: array
                    example:
                      - 1
                    items:
                      type: integer
                  courses:
                    type: array
                    example:
                      -
                        label: 'Course 1'
                        value: 1
                      -
                        label: 'Course 2'
                        value: 2
                    items:
                      type: object
                      properties:
                        label:
                          type: string
                          example: 'Course 1'
                        value:
                          type: integer
                          example: 1
                  prerequisites:
                    type: object
                    properties:
                      1:
                        type: boolean
                        example: true
                      2:
                        type: boolean
                        example: false
                  categories:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
      tags:
        - 'Learning Paths'
      security: []
  '/api/learning-path/edit/{id}':
    put:
      summary: 'Update Learning Path'
      operationId: updateLearningPath
      description: 'Updates an existing learning path with courses, certificates, prerequisites and categories.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Learning Path was successfully updated'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Learning Path was successfully updated'
      tags:
        - 'Learning Paths'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'ID of the learning path.'
                  example: 1
                name:
                  type: string
                  description: 'Name of the learning path.'
                  example: 'Learning Path 1'
                instructions:
                  type: string
                  description: 'Instruction for the learning path.'
                  example: 'Some Instruction'
                featuredImageUrl:
                  type: string
                  description: 'Image for the learning path.'
                  example: img_path
                credits:
                  type: integer
                  description: 'Credit after learning path completion, used in certificates.'
                  example: 70
                status:
                  type: string
                  description: 'learning path is in Draft or Publish mode. Status options: draft or publish.'
                  example: publish
                certificates:
                  type: array
                  description: 'Certificates attached to this learning path.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
                prerequisites:
                  type: array
                  description: 'Prerequisites courses of the learning path.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
                courses:
                  type: array
                  description: 'All courses you want to attach to this learning path. Minimum 2 courses are required'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                categories:
                  type: array
                  description: 'Categories for this learning path.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
              required:
                - id
                - name
                - status
                - courses
      security: []
  /api/learning-path/delete:
    post:
      summary: 'Delete Learning Path'
      operationId: deleteLearningPath
      description: 'Deletes the learning paths and related mapping.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '1 learning path(s) deleted, 1 learning path(s) not deleted as it has enrollments. Please remove the students from the learning path and try again.'
                  deletedLearningPaths: 1
                  notDeletedLearningPaths:
                    - 1
                  enrolledLearningPaths:
                    -
                      id: 1
                      name: 'Learning path 1'
                  notDeletedPortalLearningPaths:
                    - 1
                  portalLearningPaths:
                    'Learning path 1':
                      -
                        id: 1
                        name: 'Portal 1'
                  notDeletedProductLearningPath:
                    - 1
                  productLearningPaths:
                    -
                      id: 1
                      title: 'Product 1'
                properties:
                  message:
                    type: string
                    example: '1 learning path(s) deleted, 1 learning path(s) not deleted as it has enrollments. Please remove the students from the learning path and try again.'
                  deletedLearningPaths:
                    type: integer
                    example: 1
                  notDeletedLearningPaths:
                    type: array
                    example:
                      - 1
                    items:
                      type: integer
                  enrolledLearningPaths:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Learning path 1'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Learning path 1'
                  notDeletedPortalLearningPaths:
                    type: array
                    example:
                      - 1
                    items:
                      type: integer
                  portalLearningPaths:
                    type: object
                    properties:
                      'Learning path 1':
                        type: array
                        example:
                          -
                            id: 1
                            name: 'Portal 1'
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 1
                            name:
                              type: string
                              example: 'Portal 1'
                  notDeletedProductLearningPath:
                    type: array
                    example:
                      - 1
                    items:
                      type: integer
                  productLearningPaths:
                    type: array
                    example:
                      -
                        id: 1
                        title: 'Product 1'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: 'Product 1'
      tags:
        - 'Learning Paths'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: array
                  description: 'Array of learning path IDs to be deleted.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - delete_ids
      security: []
  /api/learning-path/lookup:
    post:
      summary: 'Learning Path Lookup'
      operationId: learningPathLookup
      description: 'Retrieves Learning Path details based on the search query.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  learning_paths:
                    -
                      value: 1
                      label: 'Learning Path 1'
                    -
                      value: 2
                      label: 'Learning Path 2'
                properties:
                  learning_paths:
                    type: array
                    example:
                      -
                        value: 1
                        label: 'Learning Path 1'
                      -
                        value: 2
                        label: 'Learning Path 2'
                    items:
                      type: object
                      properties:
                        value:
                          type: integer
                          example: 1
                        label:
                          type: string
                          example: 'Learning Path 1'
      tags:
        - 'Learning Paths'
      security: []
    parameters:
      -
        in: path
        name: search_term
        description: 'Search term for the learning paths.'
        example: '"Learning Path"'
        required: true
        schema:
          type: string
  /api/enrolled-users:
    get:
      summary: 'Enrolled Students'
      operationId: enrolledStudents
      description: 'Retrieves all enrolled students for a learning path.'
      parameters:
        -
          in: query
          name: learning_path_id
          description: 'The ID of learning path.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of learning path.'
            example: '1'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: '5'
          required: true
          schema:
            type: string
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: '5'
        -
          in: query
          name: page_size
          description: 'Number of the results you want in each page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'Number of the results you want in each page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current Page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current Page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'Returns details in some order.'
          example: registered_on
          required: false
          schema:
            type: string
            description: 'Returns details in some order.'
            example: registered_on
        -
          in: query
          name: search_param
          description: 'Search parameters related to course.'
          example: '{"status":["Not Started","In Progress"],"nameOrEmail":"John Doe"}'
          required: false
          schema:
            type: string
            description: 'Search parameters related to course.'
            example: '{"status":["Not Started","In Progress"],"nameOrEmail":"John Doe"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  learningPathName: 'Learning Path 1'
                  featuredImage: 'http://localhost:8000/storage/learning_paths/1/featured_image.jpg'
                  recordsTotal: 12
                  totalNotStarted: 3
                  totalInProgress: 4
                  totalCompleted: 5
                  recordsFiltered: 12
                  records:
                    -
                      id: 1
                      user_id: 2
                      first_name: John
                      last_name: Doe
                      email: john@example.com
                      avatar: 'http://localhost:8000/storage/users/2/avatar.jpg'
                      status: 'Not Started'
                      display_status: 'Not Started'
                      percentComplete: 0
                      access_status: Allowed
                      registered_on: 'Aug 09, 2020'
                      started_on: ''
                      completed_on: ''
                      expire_on: Never
                      last_accessed_on: Never
                      certificate_count: 0
                      user_type: Learner
                      raw_user_type: learner
                properties:
                  learningPathName:
                    type: string
                    example: 'Learning Path 1'
                  featuredImage:
                    type: string
                    example: 'http://localhost:8000/storage/learning_paths/1/featured_image.jpg'
                  recordsTotal:
                    type: integer
                    example: 12
                  totalNotStarted:
                    type: integer
                    example: 3
                  totalInProgress:
                    type: integer
                    example: 4
                  totalCompleted:
                    type: integer
                    example: 5
                  recordsFiltered:
                    type: integer
                    example: 12
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        user_id: 2
                        first_name: John
                        last_name: Doe
                        email: john@example.com
                        avatar: 'http://localhost:8000/storage/users/2/avatar.jpg'
                        status: 'Not Started'
                        display_status: 'Not Started'
                        percentComplete: 0
                        access_status: Allowed
                        registered_on: 'Aug 09, 2020'
                        started_on: ''
                        completed_on: ''
                        expire_on: Never
                        last_accessed_on: Never
                        certificate_count: 0
                        user_type: Learner
                        raw_user_type: learner
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        user_id:
                          type: integer
                          example: 2
                        first_name:
                          type: string
                          example: John
                        last_name:
                          type: string
                          example: Doe
                        email:
                          type: string
                          example: john@example.com
                        avatar:
                          type: string
                          example: 'http://localhost:8000/storage/users/2/avatar.jpg'
                        status:
                          type: string
                          example: 'Not Started'
                        display_status:
                          type: string
                          example: 'Not Started'
                        percentComplete:
                          type: integer
                          example: 0
                        access_status:
                          type: string
                          example: Allowed
                        registered_on:
                          type: string
                          example: 'Aug 09, 2020'
                        started_on:
                          type: string
                          example: ''
                        completed_on:
                          type: string
                          example: ''
                        expire_on:
                          type: string
                          example: Never
                        last_accessed_on:
                          type: string
                          example: Never
                        certificate_count:
                          type: integer
                          example: 0
                        user_type:
                          type: string
                          example: Learner
                        raw_user_type:
                          type: string
                          example: learner
      tags:
        - 'Learning Paths'
      security: []
  '/api/learning-path/enroll/{id}':
    post:
      summary: 'Enroll Students'
      operationId: enrollStudents
      description: 'To enroll users in a learning path, you need to use this request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '2 student(s) enrolled successfully'
                  enrolledUsersCount: 2
                  notEnrolledUsers: 0
                properties:
                  message:
                    type: string
                    example: '2 student(s) enrolled successfully'
                  enrolledUsersCount:
                    type: integer
                    example: 2
                  notEnrolledUsers:
                    type: integer
                    example: 0
      tags:
        - 'Learning Paths'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                studentIds:
                  type: array
                  description: 'User IDs needs to be enrolled in this learning path.'
                  example:
                    - 2
                    - 3
                  items:
                    type: string
                portalId:
                  type: integer
                  description: 'optional The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
                  example: 5
              required:
                - studentIds
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the learning path.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/learning-path/remove/{id}':
    post:
      summary: 'Remove Learners'
      operationId: removeLearners
      description: 'To removes users from a learning path, you need to use this request.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '2 student(s) removed successfully'
                properties:
                  message:
                    type: string
                    example: '2 student(s) removed successfully'
      tags:
        - 'Learning Paths'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enrollmentIds:
                  type: array
                  description: 'Enrollment IDs needs to be removed from this learning path.'
                  example:
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - enrollmentIds
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the learning path.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/learning-path/assignCertificate/{id}':
    post:
      summary: 'Assign Certificate'
      operationId: assignCertificate
      description: "Assigns a certificate to the users enrolled in a learning path using their enrollment IDs.\nChecks if the learning path has a certificate template available before proceeding with the assignment."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  isSucess: true
                  message: 'Certificate assigned successfully to 2 student(s)'
                properties:
                  isSucess:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Certificate assigned successfully to 2 student(s)'
      tags:
        - 'Learning Paths'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                enrollmentIds:
                  type: array
                  description: 'Enrollment IDs that need to be assigned a certificate.'
                  example:
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - enrollmentIds
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the learning path for which the certificate is being assigned.'
        example: '1'
        required: true
        schema:
          type: string
  /api/launch:
    get:
      summary: 'Learning Path Launch'
      operationId: learningPathLaunch
      description: 'This API is used to launch learning path and get the courses associated with the learning path.'
      parameters:
        -
          in: query
          name: info
          description: 'optional If the API is called with info parameter, the API will not start the learning path, but will return the information of the learning path.'
          example: info=true
          required: false
          schema:
            type: string
            description: 'optional If the API is called with info parameter, the API will not start the learning path, but will return the information of the learning path.'
            example: info=true
        -
          in: query
          name: portalId
          description: 'Portal ID of the user.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Portal ID of the user.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Learning Path Name'
                  featuredImageUrl: 'http://example.com/featured-image.jpg'
                  instructions: 'Learning Path Instructions'
                  learningPathStatus: Active
                  status: 'Not Started'
                  display_status: 'Not Started'
                  completionPercentage: 0
                  enrollmentDate: 22-02-2022
                  certificate: 0
                  launchSlug: 'http://example.com/launch-learning-path'
                  id: 2
                  rating: 4.5
                  totalEstimatedTime: '2 hours'
                  courseData:
                    -
                      name: 'Course 1'
                      courseId: 3
                      rating: 4.5
                      status: 'Not Started'
                      completion_percentage: 0
                      featuredImageUrl: 'http://example.com/featured-image.jpg'
                      slug: 'http://example.com/launch-course'
                      display_status: 'Not Started'
                      expire_on: 22-02-2022
                      minimum_passing_percentage: 0
                      certificate: 0
                      certificate_expire_after: Never
                      isExpired: false
                      isCurrent: true
                      isLocked: false
                      estimatedCompletionTime: '1 hour'
                      userReviewAvailable: true
                      enableCourseRating: true
                properties:
                  name:
                    type: string
                    example: 'Learning Path Name'
                  featuredImageUrl:
                    type: string
                    example: 'http://example.com/featured-image.jpg'
                  instructions:
                    type: string
                    example: 'Learning Path Instructions'
                  learningPathStatus:
                    type: string
                    example: Active
                  status:
                    type: string
                    example: 'Not Started'
                  display_status:
                    type: string
                    example: 'Not Started'
                  completionPercentage:
                    type: integer
                    example: 0
                  enrollmentDate:
                    type: string
                    example: 22-02-2022
                  certificate:
                    type: integer
                    example: 0
                  launchSlug:
                    type: string
                    example: 'http://example.com/launch-learning-path'
                  id:
                    type: integer
                    example: 2
                  rating:
                    type: number
                    example: 4.5
                  totalEstimatedTime:
                    type: string
                    example: '2 hours'
                  courseData:
                    type: array
                    example:
                      -
                        name: 'Course 1'
                        courseId: 3
                        rating: 4.5
                        status: 'Not Started'
                        completion_percentage: 0
                        featuredImageUrl: 'http://example.com/featured-image.jpg'
                        slug: 'http://example.com/launch-course'
                        display_status: 'Not Started'
                        expire_on: 22-02-2022
                        minimum_passing_percentage: 0
                        certificate: 0
                        certificate_expire_after: Never
                        isExpired: false
                        isCurrent: true
                        isLocked: false
                        estimatedCompletionTime: '1 hour'
                        userReviewAvailable: true
                        enableCourseRating: true
                    items:
                      type: object
                      properties:
                        name:
                          type: string
                          example: 'Course 1'
                        courseId:
                          type: integer
                          example: 3
                        rating:
                          type: number
                          example: 4.5
                        status:
                          type: string
                          example: 'Not Started'
                        completion_percentage:
                          type: integer
                          example: 0
                        featuredImageUrl:
                          type: string
                          example: 'http://example.com/featured-image.jpg'
                        slug:
                          type: string
                          example: 'http://example.com/launch-course'
                        display_status:
                          type: string
                          example: 'Not Started'
                        expire_on:
                          type: string
                          example: 22-02-2022
                        minimum_passing_percentage:
                          type: integer
                          example: 0
                        certificate:
                          type: integer
                          example: 0
                        certificate_expire_after:
                          type: string
                          example: Never
                        isExpired:
                          type: boolean
                          example: false
                        isCurrent:
                          type: boolean
                          example: true
                        isLocked:
                          type: boolean
                          example: false
                        estimatedCompletionTime:
                          type: string
                          example: '1 hour'
                        userReviewAvailable:
                          type: boolean
                          example: true
                        enableCourseRating:
                          type: boolean
                          example: true
      tags:
        - 'Learning Paths'
      security: []
    parameters:
      -
        in: path
        name: registrationId
        description: 'Registration ID of the learning path.'
        example: '2'
        required: true
        schema:
          type: string
  /api/portalLearningPathInfo:
    get:
      summary: 'Get Learning Path Details'
      operationId: getLearningPathDetails
      description: ''
      parameters:
        -
          in: query
          name: learningPathId
          description: 'The ID of learning path.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of learning path.'
            example: '1'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: '5'
          required: true
          schema:
            type: string
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: '5'
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "[\n\"learningPathId\": 1,\n\"name\": \"Learning Path 1\",\n\"featuredImageUrl\": \"http://localhost:8000/storage/learning_paths/1/featured_image.jpg\",\n\"instructions\": \"Sample instructions\",\n\"learningPathStatus\": \"Active\",\n\"status\": \"Not Enrolled\",\n\"display_status\": \"Not Enrolled\",\n\"completionPercentage\": 0,\n\"enrollmentDate\": \"null\",\n\"certificate\": 0,\n\"totalEstimatedTime\": \"1 hour\",\n\"rating\": 4.5,\n\"launchSlug\": \"http://localhost:8000/portal/5/learning_path/1/launch\",\n\"courseList\": [\n     {\n         \"id\": 1,\n         \"name\": \"Course 1\",\n         \"description\": \"Sample description\",\n         \"rating\": 4.5,\n         \"estimatedCompletionTime\": \"1 hour\",\n         \"featuredImageUrl\": \"http://localhost:8000/storage/courses/1/featured_image.jpg\",\n         \"status\": \"Active\",\n         \"completionPercentage\": 0,\n         \"status\": \"Not Enrolled\",\n         \"display_status\": \"Not Enrolled\"\n     }\n]\n]"
      tags:
        - 'Learning Paths'
      security: []
  /api/learning-paths/dropdownlist:
    get:
      summary: 'Learning Path Dropdown List'
      operationId: learningPathDropdownList
      description: "Returns a list of learning paths with their ID and Name based on the provided portal ID and search term.\nIf a valid portal ID is provided, it filters learning paths associated with the portal.\nIf no portal ID or an invalid one (e.g., -1) is given, it returns all learning paths."
      parameters:
        -
          in: query
          name: portalId
          description: 'The portal ID to filter learning paths by portal. Use -1 to skip portal filtering.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'The portal ID to filter learning paths by portal. Use -1 to skip portal filtering.'
            example: 5
        -
          in: query
          name: type
          description: 'The type of listing required (private/public).'
          example: public
          required: false
          schema:
            type: string
            description: 'The type of listing required (private/public).'
            example: public
        -
          in: query
          name: search_term
          description: 'The search term to filter learning paths by name.'
          example: '"Advanced"'
          required: false
          schema:
            type: string
            description: 'The search term to filter learning paths by name.'
            example: '"Advanced"'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'Learning Path 1'
                  -
                    id: 2
                    name: 'Learning Path 2'
      tags:
        - 'Learning Paths'
      security: []
  /api/learning-path/reports/learning-path-detailed:
    get:
      summary: 'Learning Path Detail Report'
      operationId: learningPathDetailReport
      description: 'Retrieves learning path detail report based on the parameters provided.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of results per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of results per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'optional The column to sort the results by.'
          example: '{"colName": "registered_on", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'optional The column to sort the results by.'
            example: '{"colName": "registered_on", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'optional The search query parameters.'
          example: '{"status": ["registered", "started"], "registered_on": ["2021-01-01", "2021-01-31"], "completed_on": ["2021-01-01", "2021-01-31"], "nameOrEmail": "John Doe"}'
          required: false
          schema:
            type: string
            description: 'optional The search query parameters.'
            example: '{"status": ["registered", "started"], "registered_on": ["2021-01-01", "2021-01-31"], "completed_on": ["2021-01-01", "2021-01-31"], "nameOrEmail": "John Doe"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsFiltered: 10
                  records:
                    -
                      user_id: 1
                      first_name: John
                      last_name: Doe
                      email: john@example.com
                      learning_path_name: 'Learning Path 1'
                      status: registered
                      display_status: Registered
                      registered_on: 01-Jan-2021
                      started_on: 05-Jan-2021
                      completed_on: 10-Jan-2021
                      last_accessed_on: 10-Jan-2021
                      certifcate_issued: 'Yes'
                      courseDetails: []
                      total_time_spent: 10
                      expire_on: Never
                      completed_lp_courses: 2
                      total_lp_courses: 5
                      portalName: 'Portal 1'
                    -
                      user_id: 2
                      first_name: Jane
                      last_name: Doe
                      email: jane@example.com
                      learning_path_name: 'Learning Path 2'
                      status: started
                      display_status: Started
                      registered_on: 01-Jan-2021
                      started_on: 05-Jan-2021
                      completed_on: 10-Jan-2021
                      last_accessed_on: 10-Jan-2021
                      certifcate_issued: 'No'
                      courseDetails: []
                      total_time_spent: 10
                      expire_on: Never
                      completed_lp_courses: 2
                      total_lp_courses: 5
                      portalName: 'Portal 1'
                properties:
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        user_id: 1
                        first_name: John
                        last_name: Doe
                        email: john@example.com
                        learning_path_name: 'Learning Path 1'
                        status: registered
                        display_status: Registered
                        registered_on: 01-Jan-2021
                        started_on: 05-Jan-2021
                        completed_on: 10-Jan-2021
                        last_accessed_on: 10-Jan-2021
                        certifcate_issued: 'Yes'
                        courseDetails: []
                        total_time_spent: 10
                        expire_on: Never
                        completed_lp_courses: 2
                        total_lp_courses: 5
                        portalName: 'Portal 1'
                      -
                        user_id: 2
                        first_name: Jane
                        last_name: Doe
                        email: jane@example.com
                        learning_path_name: 'Learning Path 2'
                        status: started
                        display_status: Started
                        registered_on: 01-Jan-2021
                        started_on: 05-Jan-2021
                        completed_on: 10-Jan-2021
                        last_accessed_on: 10-Jan-2021
                        certifcate_issued: 'No'
                        courseDetails: []
                        total_time_spent: 10
                        expire_on: Never
                        completed_lp_courses: 2
                        total_lp_courses: 5
                        portalName: 'Portal 1'
                    items:
                      type: object
                      properties:
                        user_id:
                          type: integer
                          example: 1
                        first_name:
                          type: string
                          example: John
                        last_name:
                          type: string
                          example: Doe
                        email:
                          type: string
                          example: john@example.com
                        learning_path_name:
                          type: string
                          example: 'Learning Path 1'
                        status:
                          type: string
                          example: registered
                        display_status:
                          type: string
                          example: Registered
                        registered_on:
                          type: string
                          example: 01-Jan-2021
                        started_on:
                          type: string
                          example: 05-Jan-2021
                        completed_on:
                          type: string
                          example: 10-Jan-2021
                        last_accessed_on:
                          type: string
                          example: 10-Jan-2021
                        certifcate_issued:
                          type: string
                          example: 'Yes'
                        courseDetails:
                          type: array
                          example: []
                        total_time_spent:
                          type: integer
                          example: 10
                        expire_on:
                          type: string
                          example: Never
                        completed_lp_courses:
                          type: integer
                          example: 2
                        total_lp_courses:
                          type: integer
                          example: 5
                        portalName:
                          type: string
                          example: 'Portal 1'
      tags:
        - 'Learning Paths'
      security: []
    parameters:
      -
        in: path
        name: searchPortalIds
        description: 'Portal IDs to filter learning paths by portal.'
        example: '[1,2]'
        required: true
        schema:
          type: string
      -
        in: path
        name: learning_path_ids
        description: 'Learning Path IDs to filter learning paths by ID.'
        example: '[1,2]'
        required: true
        schema:
          type: string
  /api/learning-path/reports/overview:
    get:
      summary: 'Retrieves an overview report of learning paths, including the status of enrollments.'
      operationId: retrievesAnOverviewReportOfLearningPathsIncludingTheStatusOfEnrollments
      description: "This function aggregates the enrollment statuses (Not Started, In Progress, Completed)\nfor each learning path, and calculates the percentage of completed enrollments.\nIt takes into account portal-specific filters if provided."
      parameters:
        -
          in: query
          name: searchPortalIds
          description: 'Optional array of portal IDs for filtering learning paths.'
          example:
            - 1
            - 2
          required: false
          schema:
            type: array
            description: 'Optional array of portal IDs for filtering learning paths.'
            example:
              - 1
              - 2
            items:
              type: string
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  labels:
                    - 'Learning Path 1'
                    - 'Learning Path 2'
                  totalNotStarted:
                    - 5
                    - 3
                  totalInProgress:
                    - 2
                    - 4
                  totalCompleted:
                    - 3
                    - 3
                  percentageCompleted:
                    - 30
                    - 50
                  sumNotStarted: 8
                  sumInProgress: 6
                  sumCompleted: 6
                  sumPercentageCompleted: 37
                properties:
                  labels:
                    type: array
                    example:
                      - 'Learning Path 1'
                      - 'Learning Path 2'
                    items:
                      type: string
                  totalNotStarted:
                    type: array
                    example:
                      - 5
                      - 3
                    items:
                      type: integer
                  totalInProgress:
                    type: array
                    example:
                      - 2
                      - 4
                    items:
                      type: integer
                  totalCompleted:
                    type: array
                    example:
                      - 3
                      - 3
                    items:
                      type: integer
                  percentageCompleted:
                    type: array
                    example:
                      - 30
                      - 50
                    items:
                      type: integer
                  sumNotStarted:
                    type: integer
                    example: 8
                  sumInProgress:
                    type: integer
                    example: 6
                  sumCompleted:
                    type: integer
                    example: 6
                  sumPercentageCompleted:
                    type: integer
                    example: 37
      tags:
        - 'Learning Paths'
      security: []
  /api/learning-path/clone:
    post:
      summary: 'Clone a learning path'
      operationId: cloneALearningPath
      description: "This function clones a learning path and its associated courses and categories.\nIt takes into account the user who initiated the request and records the user as the creator and updater of the cloned learning path."
      parameters:
        -
          in: query
          name: learningPathId
          description: 'The ID of learning path to clone.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of learning path to clone.'
            example: '1'
        -
          in: query
          name: isDeepCopy
          description: 'Whether to clone the learning path with its courses and categories.'
          example: 'true'
          required: true
          schema:
            type: string
            description: 'Whether to clone the learning path with its courses and categories.'
            example: 'true'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Learning Path Cloned Successfully'
                properties:
                  message:
                    type: string
                    example: 'Learning Path Cloned Successfully'
      tags:
        - 'Learning Paths'
      security: []
  /api/learning-path-activities:
    get:
      summary: 'Learning Path Activities'
      operationId: learningPathActivities
      description: "Retrieves all the activities for a learning path based on the context provided.\nContext can be either 'portal' or 'lp'.\nIf context is 'portal', it will return all activities for the portal.\nIf context is 'lp', it will return all activities for the learning path."
      parameters:
        -
          in: query
          name: learning_path_id
          description: 'The ID of learning path.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of learning path.'
            example: '1'
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'For searching items based on field names.'
          example: '{"name":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on field names.'
            example: '{"name":""}'
        -
          in: query
          name: context
          description: 'The context of the activities.'
          example: 'portal or lp'
          required: true
          schema:
            type: string
            description: 'The context of the activities.'
            example: 'portal or lp'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter activities by portal.'
          example: '5'
          required: true
          schema:
            type: string
            description: 'The portal ID to filter activities by portal.'
            example: '5'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      name: 'Test Activity'
                      status: PUBLISHED
                      created_at: 'Aug 03, 2020 09:31 AM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Test Activity'
                        status: PUBLISHED
                        created_at: 'Aug 03, 2020 09:31 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Test Activity'
                        status:
                          type: string
                          example: PUBLISHED
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:31 AM'
      tags:
        - 'Learning Paths'
      security: []
  /api/learning-path-activities/verb/lookup:
    get:
      summary: 'Learning Path Activities Lookup'
      operationId: learningPathActivitiesLookup
      description: "Retrieves all the activities name performed by students in a learning path.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: ENROLLED
                    display_value: ENROLLED
                  -
                    db_value: STARTED
                    display_value: STARTED
                  -
                    db_value: ACCESSED
                    display_value: ACCESSED
                  -
                    db_value: COMPLETED
                    display_value: COMPLETED
                  -
                    db_value: 'ACHIEVED CERTIFICATE'
                    display_value: 'ACHIEVED CERTIFICATE'
                  -
                    db_value: REMOVED
                    display_value: REMOVED
      tags:
        - 'Learning Paths'
      security: []
  /api/location/create:
    post:
      summary: 'Create a new location.'
      operationId: createANewLocation
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Location Created Successfully'
                properties:
                  message:
                    type: string
                    example: 'Location Created Successfully'
      tags:
        - Location
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                location_name:
                  type: required
                  description: 'The name of the location.'
                  example: 'New York'
                address:
                  type: The
                  description: 'address of the location.'
                  example: 'New York, USA'
                city:
                  type: The
                  description: 'city of the location.'
                  example: 'New York'
                country:
                  type: The
                  description: 'country of the location.'
                  example: USA
                zipcode:
                  type: The
                  description: 'zipcode of the location.'
                  example: '10001'
                map_url:
                  type: The
                  description: 'map URL of the location.'
                  example: 'https://www.google.com/maps/search/?api=1&query=New+York'
      security: []
  /api/location/tabularlist:
    get:
      summary: 'Location Tabular List'
      operationId: locationTabularList
      description: "Retrieves all the locations in a tabular list format with pagination mode.\nYou can apply filter using search_param via locationName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the locations you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the locations you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on location name.'
          example: '{"locationName":"New York"}'
          required: false
          schema:
            type: string
            description: 'for searching items based on location name.'
            example: '{"locationName":"New York"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      name: 'New York'
                      address: 'New York, USA'
                      city: 'New York'
                      country: USA
                      zipcode: '10001'
                      map_url: 'https://www.google.com/maps/search/?api=1&query=New+York'
                      created_at: 'Aug 11, 2020 02:12 PM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'New York'
                        address: 'New York, USA'
                        city: 'New York'
                        country: USA
                        zipcode: '10001'
                        map_url: 'https://www.google.com/maps/search/?api=1&query=New+York'
                        created_at: 'Aug 11, 2020 02:12 PM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'New York'
                        address:
                          type: string
                          example: 'New York, USA'
                        city:
                          type: string
                          example: 'New York'
                        country:
                          type: string
                          example: USA
                        zipcode:
                          type: string
                          example: '10001'
                        map_url:
                          type: string
                          example: 'https://www.google.com/maps/search/?api=1&query=New+York'
                        created_at:
                          type: string
                          example: 'Aug 11, 2020 02:12 PM'
      tags:
        - Location
      security: []
  '/api/location/{id}':
    get:
      summary: 'Get Location'
      operationId: getLocation
      description: 'Retrieves an existing location by given ID.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'New York'
                  address: 'New York, USA'
                  city: 'New York'
                  country: USA
                  zipcode: '10001'
                  map_url: 'https://www.google.com/maps/search/?api=1&query=New+York'
                  created_by: 1
                  created_at: '2020-08-11 02:12:00'
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'New York'
                  address:
                    type: string
                    example: 'New York, USA'
                  city:
                    type: string
                    example: 'New York'
                  country:
                    type: string
                    example: USA
                  zipcode:
                    type: string
                    example: '10001'
                  map_url:
                    type: string
                    example: 'https://www.google.com/maps/search/?api=1&query=New+York'
                  created_by:
                    type: integer
                    example: 1
                  created_at:
                    type: string
                    example: '2020-08-11 02:12:00'
      tags:
        - Location
      security: []
    put:
      summary: 'Update Location'
      operationId: updateLocation
      description: "Updates an existing location's details using the provided ID."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Location Updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Location Updated Successfully'
      tags:
        - Location
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                location_name:
                  type: string
                  description: 'The name of the location.'
                  example: 'New York'
                address:
                  type: string
                  description: 'The address of the location.'
                  example: 'New York, USA'
                city:
                  type: string
                  description: 'The city of the location.'
                  example: 'New York'
                country:
                  type: string
                  description: 'The country of the location.'
                  example: USA
                zipcode:
                  type: string
                  description: 'The zipcode of the location.'
                  example: '10001'
                map_url:
                  type: string
                  description: 'The map URL of the location.'
                  example: 'https://www.google.com/maps/search/?api=1&query=New+York'
              required:
                - location_name
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the location to be retrieved.'
        example: 1
        required: true
        schema:
          type: integer
  /api/location/delete:
    post:
      summary: 'Delete Location'
      operationId: deleteLocation
      description: "To delete a location, you need to use this request.\nReturns number of location deleted(if multiple selected) and also not deleted. (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '3 location(s) deleted 2 location(s) not deleted as it is used in class(s). Please remove the location from the class(s) and try again.'
                  deletedLocations: 3
                properties:
                  message:
                    type: string
                    example: '3 location(s) deleted 2 location(s) not deleted as it is used in class(s). Please remove the location from the class(s) and try again.'
                  deletedLocations:
                    type: integer
                    example: 3
      tags:
        - Location
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: array
                  description: 'All location IDs which needs to be deleted.'
                  example:
                    - 1
                    - 12
                    - 15
                  items:
                    type: string
              required:
                - delete_ids
      security: []
  /api/locations/lookup:
    post:
      summary: 'Location Lookup'
      operationId: locationLookup
      description: "Returns array of location data,\ncontaining location id and name."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    value: 1
                    label: 'New York'
                  -
                    value: 2
                    label: 'Los Angeles'
      tags:
        - Location
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                search_term:
                  type: string
                  description: 'The search term for location name.'
                  example: '"New York"'
              required:
                - search_term
      security: []
  /api/media:
    post:
      summary: 'Upload Media'
      operationId: uploadMedia
      description: "Handles the media upload request via both chunked and non-chunked approach.\nThe request is determined by the presence of file object in the request.\nIf the request contains a file object, it is saved directly to s3-pending folder.\nIf the request does not contain a file object, it is assumed to be a chunked upload request.\nThe chunk is saved to local chunks folder and if it is the last chunk, it is combined and saved to s3-pending folder.\nThe delete request is handled by deleting the chunks folder for the given deleteId."
      parameters:
        -
          in: query
          name: patch
          description: 'The file handler ID that is used to identify the chunked upload request.'
          example: ut
          required: false
          schema:
            type: string
            description: 'The file handler ID that is used to identify the chunked upload request.'
            example: ut
        -
          in: query
          name: deleteId
          description: 'The file handler ID that is used to identify the chunked upload request to be deleted.'
          example: nobis
          required: false
          schema:
            type: string
            description: 'The file handler ID that is used to identify the chunked upload request to be deleted.'
            example: nobis
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: true
                  code: 200
                  errorMessage: null
                  uploadedMedia:
                    id: 3
                    file_name: default-certificate-8741bc53eb39d4154c232925c0f13088.png
                    file_type: Images
                    status: Completed
                    s3_url: 'https://aom-uploads-test.s3.us-west-2.amazonaws.com/public/default-certificate-8741bc53eb39d4154c232925c0f13088.png'
                    mux_url: null
                    mime_type: image/png
                    created_at: 'Aug 12, 2020 09:02 AM'
                properties:
                  is_success:
                    type: boolean
                    example: true
                  code:
                    type: integer
                    example: 200
                  errorMessage:
                    type: string
                    example: null
                  uploadedMedia:
                    type: object
                    properties:
                      id:
                        type: integer
                        example: 3
                      file_name:
                        type: string
                        example: default-certificate-8741bc53eb39d4154c232925c0f13088.png
                      file_type:
                        type: string
                        example: Images
                      status:
                        type: string
                        example: Completed
                      s3_url:
                        type: string
                        example: 'https://aom-uploads-test.s3.us-west-2.amazonaws.com/public/default-certificate-8741bc53eb39d4154c232925c0f13088.png'
                      mux_url:
                        type: string
                        example: null
                      mime_type:
                        type: string
                        example: image/png
                      created_at:
                        type: string
                        example: 'Aug 12, 2020 09:02 AM'
      tags:
        - Media
      security: []
    patch:
      summary: 'Upload Media'
      operationId: uploadMedia
      description: "Handles the media upload request via both chunked and non-chunked approach.\nThe request is determined by the presence of file object in the request.\nIf the request contains a file object, it is saved directly to s3-pending folder.\nIf the request does not contain a file object, it is assumed to be a chunked upload request.\nThe chunk is saved to local chunks folder and if it is the last chunk, it is combined and saved to s3-pending folder.\nThe delete request is handled by deleting the chunks folder for the given deleteId."
      parameters:
        -
          in: query
          name: patch
          description: 'The file handler ID that is used to identify the chunked upload request.'
          example: ullam
          required: false
          schema:
            type: string
            description: 'The file handler ID that is used to identify the chunked upload request.'
            example: ullam
        -
          in: query
          name: deleteId
          description: 'The file handler ID that is used to identify the chunked upload request to be deleted.'
          example: sit
          required: false
          schema:
            type: string
            description: 'The file handler ID that is used to identify the chunked upload request to be deleted.'
            example: sit
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: true
                  code: 200
                  errorMessage: null
                  uploadedMedia:
                    id: 3
                    file_name: default-certificate-8741bc53eb39d4154c232925c0f13088.png
                    file_type: Images
                    status: Completed
                    s3_url: 'https://aom-uploads-test.s3.us-west-2.amazonaws.com/public/default-certificate-8741bc53eb39d4154c232925c0f13088.png'
                    mux_url: null
                    mime_type: image/png
                    created_at: 'Aug 12, 2020 09:02 AM'
                properties:
                  is_success:
                    type: boolean
                    example: true
                  code:
                    type: integer
                    example: 200
                  errorMessage:
                    type: string
                    example: null
                  uploadedMedia:
                    type: object
                    properties:
                      id:
                        type: integer
                        example: 3
                      file_name:
                        type: string
                        example: default-certificate-8741bc53eb39d4154c232925c0f13088.png
                      file_type:
                        type: string
                        example: Images
                      status:
                        type: string
                        example: Completed
                      s3_url:
                        type: string
                        example: 'https://aom-uploads-test.s3.us-west-2.amazonaws.com/public/default-certificate-8741bc53eb39d4154c232925c0f13088.png'
                      mux_url:
                        type: string
                        example: null
                      mime_type:
                        type: string
                        example: image/png
                      created_at:
                        type: string
                        example: 'Aug 12, 2020 09:02 AM'
      tags:
        - Media
      security: []
    delete:
      summary: 'Upload Media'
      operationId: uploadMedia
      description: "Handles the media upload request via both chunked and non-chunked approach.\nThe request is determined by the presence of file object in the request.\nIf the request contains a file object, it is saved directly to s3-pending folder.\nIf the request does not contain a file object, it is assumed to be a chunked upload request.\nThe chunk is saved to local chunks folder and if it is the last chunk, it is combined and saved to s3-pending folder.\nThe delete request is handled by deleting the chunks folder for the given deleteId."
      parameters:
        -
          in: query
          name: patch
          description: 'The file handler ID that is used to identify the chunked upload request.'
          example: quasi
          required: false
          schema:
            type: string
            description: 'The file handler ID that is used to identify the chunked upload request.'
            example: quasi
        -
          in: query
          name: deleteId
          description: 'The file handler ID that is used to identify the chunked upload request to be deleted.'
          example: in
          required: false
          schema:
            type: string
            description: 'The file handler ID that is used to identify the chunked upload request to be deleted.'
            example: in
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: true
                  code: 200
                  errorMessage: null
                  uploadedMedia:
                    id: 3
                    file_name: default-certificate-8741bc53eb39d4154c232925c0f13088.png
                    file_type: Images
                    status: Completed
                    s3_url: 'https://aom-uploads-test.s3.us-west-2.amazonaws.com/public/default-certificate-8741bc53eb39d4154c232925c0f13088.png'
                    mux_url: null
                    mime_type: image/png
                    created_at: 'Aug 12, 2020 09:02 AM'
                properties:
                  is_success:
                    type: boolean
                    example: true
                  code:
                    type: integer
                    example: 200
                  errorMessage:
                    type: string
                    example: null
                  uploadedMedia:
                    type: object
                    properties:
                      id:
                        type: integer
                        example: 3
                      file_name:
                        type: string
                        example: default-certificate-8741bc53eb39d4154c232925c0f13088.png
                      file_type:
                        type: string
                        example: Images
                      status:
                        type: string
                        example: Completed
                      s3_url:
                        type: string
                        example: 'https://aom-uploads-test.s3.us-west-2.amazonaws.com/public/default-certificate-8741bc53eb39d4154c232925c0f13088.png'
                      mux_url:
                        type: string
                        example: null
                      mime_type:
                        type: string
                        example: image/png
                      created_at:
                        type: string
                        example: 'Aug 12, 2020 09:02 AM'
      tags:
        - Media
      security: []
  /api/media/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the media in a tabular list format with pagination mode.\nYou can apply filter using search_param via name(media name), file_type(file type)."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the media you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the media you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on media name, file type.'
          example: '{"name":"media name","file_type":"Images"}'
          required: false
          schema:
            type: string
            description: 'for searching items based on media name, file type.'
            example: '{"name":"media name","file_type":"Images"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 4
                  recordsFiltered: 4
                  records:
                    -
                      id: 4
                      file_name: default-certificate-8741bc53eb39d4154c232925c0f13088.png
                      file_type: Images
                      status: Completed
                      s3_url: 'https://aom-uploads-test.s3.us-west-2.amazonaws.com/public/default-certificate-8741bc53eb39d4154c232925c0f13088.png'
                      mux_url: null
                      mime_type: image/png
                      created_at: 'Aug 12, 2020 09:02 AM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 4
                  recordsFiltered:
                    type: integer
                    example: 4
                  records:
                    type: array
                    example:
                      -
                        id: 4
                        file_name: default-certificate-8741bc53eb39d4154c232925c0f13088.png
                        file_type: Images
                        status: Completed
                        s3_url: 'https://aom-uploads-test.s3.us-west-2.amazonaws.com/public/default-certificate-8741bc53eb39d4154c232925c0f13088.png'
                        mux_url: null
                        mime_type: image/png
                        created_at: 'Aug 12, 2020 09:02 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 4
                        file_name:
                          type: string
                          example: default-certificate-8741bc53eb39d4154c232925c0f13088.png
                        file_type:
                          type: string
                          example: Images
                        status:
                          type: string
                          example: Completed
                        s3_url:
                          type: string
                          example: 'https://aom-uploads-test.s3.us-west-2.amazonaws.com/public/default-certificate-8741bc53eb39d4154c232925c0f13088.png'
                        mux_url:
                          type: string
                          example: null
                        mime_type:
                          type: string
                          example: image/png
                        created_at:
                          type: string
                          example: 'Aug 12, 2020 09:02 AM'
      tags:
        - Media
      security: []
  /api/media/delete:
    post:
      summary: 'Delete Media'
      operationId: deleteMedia
      description: "This API is used to delete the uploaded media from the storage.\nIt will also delete the video files from MUX if the file type is Video."
      parameters:
        -
          in: query
          name: delete_ids
          description: 'The array of media IDs which needs to be deleted. example: [1,2,3]'
          example: qui
          required: true
          schema:
            type: string
            description: 'The array of media IDs which needs to be deleted. example: [1,2,3]'
            example: qui
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '2 media(s) deleted'
                  errorMessage: '2 media(s) not deleted, Something went wrong! try again'
                  fileNotDeleted: 2
                properties:
                  message:
                    type: string
                    example: '2 media(s) deleted'
                  errorMessage:
                    type: string
                    example: '2 media(s) not deleted, Something went wrong! try again'
                  fileNotDeleted:
                    type: integer
                    example: 2
      tags:
        - Media
      security: []
  /api/media/status:
    get:
      summary: 'Get Media Status'
      operationId: getMediaStatus
      description: 'Returns the status of the uploaded media. (See Response)'
      parameters:
        -
          in: query
          name: id
          description: 'The ID of the media.'
          example: error
          required: true
          schema:
            type: string
            description: 'The ID of the media.'
            example: error
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: Completed
                properties:
                  status:
                    type: string
                    example: Completed
      tags:
        - Media
      security: []
  /api/media/mux/download:
    post:
      summary: 'Download Mux Video'
      operationId: downloadMuxVideo
      description: "This API is used to download the uploaded video from MUX service.\nIf the master access is not enabled as temporary, this API will enable it.\nIf the master access is already enabled as temporary, this API will return the download URL directly."
      parameters:
        -
          in: query
          name: mux_id
          description: 'The MUX ID of the video to download.'
          example: 7K0103V01NFz01
          required: true
          schema:
            type: string
            description: 'The MUX ID of the video to download.'
            example: 7K0103V01NFz01
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: ready
                  downloadUrl: 'https://stream.mux.com/7K0103V01NFz01?download=1&filename=example.mp4'
                properties:
                  status:
                    type: string
                    example: ready
                  downloadUrl:
                    type: string
                    example: 'https://stream.mux.com/7K0103V01NFz01?download=1&filename=example.mp4'
      tags:
        - Media
      security: []
  /api/media/saveVideo:
    post:
      summary: 'Save Video'
      operationId: saveVideo
      description: "This API is used to save the uploaded video media to the database.\nIt takes videoGuid and fileName as input and returns the uploaded media."
      parameters:
        -
          in: query
          name: videoGuid
          description: 'The videoGuid of the uploaded video.'
          example: d2c0faa3-9d15-49c4-ae11-9b2c9a5c0a7c
          required: true
          schema:
            type: string
            description: 'The videoGuid of the uploaded video.'
            example: d2c0faa3-9d15-49c4-ae11-9b2c9a5c0a7c
        -
          in: query
          name: fileName
          description: 'The name of the uploaded video.'
          example: test.mp4
          required: true
          schema:
            type: string
            description: 'The name of the uploaded video.'
            example: test.mp4
        -
          in: query
          name: mimeType
          description: 'The mime type of the uploaded video.'
          example: video/mp4
          required: true
          schema:
            type: string
            description: 'The mime type of the uploaded video.'
            example: video/mp4
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: true
                  code: 200
                  errorMessage: 'Unable to upload the media. Please contact admin'
                  uploadedMedia:
                    id: 4
                    file_name: test.mp4
                    mime_type: video/mp4
                    bunny_video_id: d2c0faa3-9d15-49c4-ae11-9b2c9a5c0a7c
                    s3_url: 'https://aom.b-cdn.net/d2c0faa3-9d15-49c4-ae11-9b2c9a5c0a7c/original'
                    bunny_video_url: 'https://aom.b-cdn.net/d2c0faa3-9d15-49c4-ae11-9b2c9a5c0a7c/playlist.m3u8'
                    file_type: Videos
                    status: Processing
                    created_at: '2021-08-05T06:44:12.000000Z'
                    updated_at: '2021-08-05T06:44:12.000000Z'
                properties:
                  is_success:
                    type: boolean
                    example: true
                  code:
                    type: integer
                    example: 200
                  errorMessage:
                    type: string
                    example: 'Unable to upload the media. Please contact admin'
                  uploadedMedia:
                    type: object
                    properties:
                      id:
                        type: integer
                        example: 4
                      file_name:
                        type: string
                        example: test.mp4
                      mime_type:
                        type: string
                        example: video/mp4
                      bunny_video_id:
                        type: string
                        example: d2c0faa3-9d15-49c4-ae11-9b2c9a5c0a7c
                      s3_url:
                        type: string
                        example: 'https://aom.b-cdn.net/d2c0faa3-9d15-49c4-ae11-9b2c9a5c0a7c/original'
                      bunny_video_url:
                        type: string
                        example: 'https://aom.b-cdn.net/d2c0faa3-9d15-49c4-ae11-9b2c9a5c0a7c/playlist.m3u8'
                      file_type:
                        type: string
                        example: Videos
                      status:
                        type: string
                        example: Processing
                      created_at:
                        type: string
                        example: '2021-08-05T06:44:12.000000Z'
                      updated_at:
                        type: string
                        example: '2021-08-05T06:44:12.000000Z'
      tags:
        - Media
      security: []
  /api/media/bunnyDetails:
    get:
      summary: 'Get BunnyCDN Details'
      operationId: getBunnyCDNDetails
      description: "To get the BunnyCDN library id and api key, you need to use this request.\nIt will return the BunnyCDN library id and api key based on the environment.\nIf the request is from localhost, it will return the values from .env file.\nIf the request is from production environment, it will return the values from database."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  libraryId: a1b2c3d4-library-7890
                  apiKey: 9b7e4c08-3d2f-4a1c-86f2-1e4b2d8f1234
                properties:
                  libraryId:
                    type: string
                    example: a1b2c3d4-library-7890
                  apiKey:
                    type: string
                    example: 9b7e4c08-3d2f-4a1c-86f2-1e4b2d8f1234
      tags:
        - Media
      security: []
  /api/media/createBunnyVideoLibrary:
    get:
      summary: 'Create Bunny Video Library'
      operationId: createBunnyVideoLibrary
      description: "This function creates a new video library on Bunny.net. It sends a POST request\nto the Bunny API with the site title and replication regions. On successful creation,\nit updates the local configuration with the new library ID, API key, and pull zone ID.\nIt also fetches the pull zone name and updates the meta information accordingly."
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: true
                  bunny_library_id: '123456'
                  bunny_api_key: 9b7e4c08-3d2f-4a1c-86f2-1e4b2d8f1234
                properties:
                  is_success:
                    type: boolean
                    example: true
                  bunny_library_id:
                    type: string
                    example: '123456'
                  bunny_api_key:
                    type: string
                    example: 9b7e4c08-3d2f-4a1c-86f2-1e4b2d8f1234
        500:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: false
                  message: 'Error message'
                properties:
                  is_success:
                    type: boolean
                    example: false
                  message:
                    type: string
                    example: 'Error message'
      tags:
        - Media
      security: []
  /api/memberships/lookup:
    get:
      summary: 'Lookup memberships'
      operationId: lookupMemberships
      description: "Retrieves the memberships matching the search term provided in the request. If the portalId is provided, it will fetch memberships\nwhich are attached to the portal."
      parameters:
        -
          in: query
          name: search_term
          description: 'The search term to search for memberships.'
          example: 'membership 1'
          required: true
          schema:
            type: string
            description: 'The search term to search for memberships.'
            example: 'membership 1'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: '5'
          required: true
          schema:
            type: string
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: '5'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'membership 1'
                  -
                    id: 2
                    name: 'membership 2'
      tags:
        - Memberships
      security: []
  /api/memberships/tabularlist:
    get:
      summary: 'Retrieve Memberships in a Tabular List'
      operationId: retrieveMembershipsInATabularList
      description: 'Returns a paginated list of memberships in a tabular format with optional filters and sorting.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of memberships to display per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of memberships to display per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'The current page number for pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number for pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'A JSON object specifying the column and direction for sorting.'
          example: '{"colName":"created_at","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'A JSON object specifying the column and direction for sorting.'
            example: '{"colName":"created_at","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'A JSON object for filtering memberships by name.'
          example: '{"name":"Basic Membership"}'
          required: false
          schema:
            type: string
            description: 'A JSON object for filtering memberships by name.'
            example: '{"name":"Basic Membership"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 100
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      name: 'Basic Membership'
                      expired_at: '2023-12-31 23:59:59'
                      author: Admin
                      created_at: '2023-01-01 00:00:00'
                properties:
                  recordsTotal:
                    type: integer
                    example: 100
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Basic Membership'
                        expired_at: '2023-12-31 23:59:59'
                        author: Admin
                        created_at: '2023-01-01 00:00:00'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Basic Membership'
                        expired_at:
                          type: string
                          example: '2023-12-31 23:59:59'
                        author:
                          type: string
                          example: Admin
                        created_at:
                          type: string
                          example: '2023-01-01 00:00:00'
      tags:
        - Memberships
      security: []
  '/api/membership/{id}':
    get:
      summary: 'Get a membership by ID'
      operationId: getAMembershipByID
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: Gold-membership
                  courseAccess: all
                  moduleAccess: all
                  expired_at: '2021-10-03 23:59:59'
                  courseAccessCategories:
                    - 1
                    - 2
                  moduleAccessCategories:
                    - 5
                    - 19
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: Gold-membership
                  courseAccess:
                    type: string
                    example: all
                  moduleAccess:
                    type: string
                    example: all
                  expired_at:
                    type: string
                    example: '2021-10-03 23:59:59'
                  courseAccessCategories:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  moduleAccessCategories:
                    type: array
                    example:
                      - 5
                      - 19
                    items:
                      type: integer
      tags:
        - Memberships
      security: []
    put:
      summary: 'Update Membership'
      operationId: updateMembership
      description: "Updates the details of a specified membership. (See Parameters)\nMembership is being used as to couple courses and standalone modules for students to launch and view."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Membership created successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Membership created successfully'
      tags:
        - Memberships
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: required
                  description: 'The name of the membership.'
                  example: Gold-membership
                courseAccess:
                  type: required
                  description: 'The type of course access. {all, no_access, specific} Only these values allowed.'
                  example: all
                moduleAccess:
                  type: required
                  description: 'The type of module access. {all, no_access, specific} Only these values allowed.'
                  example: all
                courseAccessCategories:
                  type: array
                  description: 'Any course category IDs if you have selected specific in courseAccess parameter.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
                moduleAccessCategories:
                  type: array
                  description: 'Any module category IDs if you have selected specific in moduleAccess parameter.'
                  example:
                    - 5
                    - 19
                  items:
                    type: string
                expired_at:
                  type: string
                  description: 'Expire date for the membership.'
                  example: "'2021-10-03 23:59:59'"
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the membership.'
        example: '1'
        required: true
        schema:
          type: string
  /api/membership:
    post:
      summary: 'Create a new membership'
      operationId: createANewMembership
      description: 'Creates a new membership with course and module access rules.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Membership created successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Membership created successfully'
      tags:
        - Memberships
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: required
                  description: 'The name of the membership.'
                  example: Gold-membership
                courseAccess:
                  type: required
                  description: 'The type of course access. {all, no_access, specific} Only these values allowed.'
                  example: all
                moduleAccess:
                  type: required
                  description: 'The type of module access. {all, no_access, specific} Only these values allowed.'
                  example: all
                courseAccessCategories:
                  type: array
                  description: 'Any course category IDs if you have selected specific in courseAccess parameter.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
                moduleAccessCategories:
                  type: array
                  description: 'Any module category IDs if you have selected specific in moduleAccess parameter.'
                  example:
                    - 5
                    - 19
                  items:
                    type: string
                expired_at:
                  type: string
                  description: 'Expire date for the membership.'
                  example: "'2021-10-03 23:59:59'"
      security: []
  /api/membership/quickEdit:
    post:
      summary: 'Quick Edit'
      operationId: quickEdit
      description: 'Updates the details in bulk for a specified membership. Parameters is provided which needs to be updated.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Memberships updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Memberships updated Successfully'
      tags:
        - Memberships
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                membership_ids:
                  type: array
                  description: 'All membership IDs which needs to be updated.'
                  example:
                    - 3
                    - 2
                  items:
                    type: string
                expired_at:
                  type: string
                  description: 'Expiry date for the selected memberships.'
                  example: '2021-01-11 23:45:00'
              required:
                - membership_ids
                - expired_at
      security: []
  /api/menus/list:
    get:
      summary: 'Retrieve all the menus with all its associated items'
      operationId: retrieveAllTheMenusWithAllItsAssociatedItems
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'Main Menu'
                    items:
                      -
                        label: Home
                        type: page
                        custom_link: null
                        page_id: 1
                        display_order: 1
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: /
                      -
                        label: Courses
                        type: page
                        custom_link: null
                        page_id: 2
                        display_order: 2
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: 'http://localhost:8000/course-catalog'
                      -
                        label: 'Our Team'
                        type: page
                        custom_link: null
                        page_id: 3
                        display_order: 3
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: 'http://localhost:8000/about-us'
                      -
                        label: 'Contact Us'
                        type: page
                        custom_link: null
                        page_id: 6
                        display_order: 4
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: 'http://localhost:8000/contact-us'
                  -
                    id: 2
                    name: 'Top Bar Menu'
                    items:
                      -
                        label: Dashboard
                        type: custom_link
                        custom_link: /dashboard
                        page_id: null
                        display_order: 1
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: /dashboard
                      -
                        label: Cart
                        type: page
                        custom_link: null
                        page_id: 5
                        display_order: 2
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: 'http://localhost:8000/cart'
                  -
                    id: 3
                    name: 'Footer Menu'
                    items: []
      tags:
        - Menus
      security: []
  '/api/menus/items/{id}':
    get:
      summary: 'Get all the items associated with this menu'
      operationId: getAllTheItemsAssociatedWithThisMenu
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    label: Home
                    type: page
                    custom_link: null
                    page_id: 1
                    display_order: 1
                    css_class: null
                    restrictions: null
                    open_in_new_tab: false
                    level: 1
                    isCollapsed: true
                    hyperlink: /
                  -
                    label: Courses
                    type: page
                    custom_link: null
                    page_id: 2
                    display_order: 2
                    css_class: null
                    restrictions: null
                    open_in_new_tab: false
                    level: 1
                    isCollapsed: true
                    hyperlink: 'http://localhost:8000/course-catalog'
      tags:
        - Menus
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The id of the menu to be retrieved.'
        example: '5'
        required: true
        schema:
          type: string
  /api/menus:
    post:
      summary: 'Save or update menu items.'
      operationId: saveOrUpdateMenuItems
      description: "This endpoint accepts a list of menus with their associated items, deletes existing items,\nand inserts the new items accordingly."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Menu updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Menu updated successfully'
      tags:
        - Menus
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                menuList:
                  type: array
                  description: 'The list of menus with their items.'
                  example:
                    -
                      id: 1
                      items:
                        -
                          label: Home
                          icon: home-icon
                          type: custom
                          css_class: nav-item
                          restrictions: []
                          open_in_new_tab: false
                          level: 1
                          custom_link: /home
                  items:
                    type: string
              required:
                - menuList
      security: []
  /api/modules/addBlank:
    post:
      summary: 'Create Blank Module'
      operationId: createBlankModule
      description: "Handles the creation of a blank module with the provided name and type.\nValidates the request data and saves a new module record in the database.\nSets the created_by and updated_by fields to the ID of the authenticated user.\nReturns the ID and icon of the created module in JSON format."
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  icon: '<i class="el-icon-document"></i>'
                properties:
                  id:
                    type: integer
                    example: 1
                  icon:
                    type: string
                    example: '<i class="el-icon-document"></i>'
      tags:
        - Modules
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'The name of the module.'
                  example: Introduction
                type:
                  type: string
                  description: 'The type of the module.'
                  example: text
              required:
                - name
                - type
      security: []
  /api/modules/lookup:
    get:
      summary: 'Modules Lookup'
      operationId: modulesLookup
      description: "Retrieves all the modules. Helps while showing modules names in form elements like dropdown.\nYou can apply filters using search_term parameter. (See Response)"
      parameters:
        -
          in: query
          name: search_term
          description: 'The name or substring of the module name to search for that module.'
          example: Introduction
          required: true
          schema:
            type: string
            description: 'The name or substring of the module name to search for that module.'
            example: Introduction
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: Introduction
                    type: text
                    icon: '<i class="el-icon-document"></i>'
                    value: 1
                    label: Introduction
      tags:
        - Modules
      security: []
  /api/modules/pendingsubmissions:
    get:
      summary: 'Get Pending Module Submissions'
      operationId: getPendingModuleSubmissions
      description: "Returns the total number of pending module submissions (status = \"Submitted\") across all courses.\nAlso returns a breakdown of pending submissions grouped by course."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  totalPending: 25
                  data:
                    -
                      id: 1
                      name: 'Leadership Training'
                      featured_image_url: 'https://example.com/images/course1.jpg'
                      totalSubmission: 10
                    -
                      id: 2
                      name: 'Compliance Basics'
                      featured_image_url: 'https://example.com/images/course2.jpg'
                      totalSubmission: 15
                properties:
                  totalPending:
                    type: integer
                    example: 25
                  data:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Leadership Training'
                        featured_image_url: 'https://example.com/images/course1.jpg'
                        totalSubmission: 10
                      -
                        id: 2
                        name: 'Compliance Basics'
                        featured_image_url: 'https://example.com/images/course2.jpg'
                        totalSubmission: 15
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Leadership Training'
                        featured_image_url:
                          type: string
                          example: 'https://example.com/images/course1.jpg'
                        totalSubmission:
                          type: integer
                          example: 10
      tags:
        - Modules
      security: []
  /api/modules/type/lookup:
    get:
      summary: 'Module Types Lookup'
      operationId: moduleTypesLookup
      description: "Retrieves all the types of modules supported by the platform.\nUseful for displaying options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: text
                    display_value: Text
                  -
                    db_value: video
                    display_value: Video
                  -
                    db_value: pdf
                    display_value: PDF
                  -
                    db_value: powerpoint
                    display_value: Powerpoint
                  -
                    db_value: flashcards
                    display_value: 'Flash Cards'
                  -
                    db_value: scorm
                    display_value: SCORM/xAPI
                  -
                    db_value: quiz
                    display_value: Quiz
                  -
                    db_value: assignment
                    display_value: Assignment
                  -
                    db_value: discussion
                    display_value: Discussion
                  -
                    db_value: survey
                    display_value: Survey
      tags:
        - Modules
      security: []
  /api/modules/fieldtype/lookup:
    get:
      summary: 'Form Field Types Lookup'
      operationId: formFieldTypesLookup
      description: "Retrieves all the types of form fields that are supported for surveys.\nUseful for displaying options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: text
                    display_value: 'Survey Text'
                  -
                    db_value: textarea
                    display_value: 'Text Area'
                  -
                    db_value: rating
                    display_value: Rating
                  -
                    db_value: radio
                    display_value: 'Single Select'
                  -
                    db_value: checkbox
                    display_value: 'Multiple Select'
                  -
                    db_value: dropdown
                    display_value: 'Drop Down'
      tags:
        - Modules
      security: []
  /api/modules/tabularlist:
    get:
      summary: 'Modules Tabular List'
      operationId: modulesTabularList
      description: "Retrieves all the modules in a tabular list format in paginated mode.\nYou can apply filter using search_param via associatedCourse(modules used in course) and moduleName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName": "name", "direction": "asc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName": "name", "direction": "asc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"associatedCourse":"","moduleName":""}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"associatedCourse":"","moduleName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      name: 'Home Page'
                      slug: home-page
                      type: text
                      icon: '<i class="el-icon-document"></i>'
                      author: 'John Doe'
                      created_at: '2021-01-01 12:00:00'
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Home Page'
                        slug: home-page
                        type: text
                        icon: '<i class="el-icon-document"></i>'
                        author: 'John Doe'
                        created_at: '2021-01-01 12:00:00'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Home Page'
                        slug:
                          type: string
                          example: home-page
                        type:
                          type: string
                          example: text
                        icon:
                          type: string
                          example: '<i class="el-icon-document"></i>'
                        author:
                          type: string
                          example: 'John Doe'
                        created_at:
                          type: string
                          example: '2021-01-01 12:00:00'
      tags:
        - Modules
      security: []
  /api/module/quickEdit:
    post:
      summary: 'Quick Edit Modules'
      operationId: quickEditModules
      description: "This endpoint allows bulk updating of modules and their related details based on the provided module type.\nIt updates fields like `created_by`, `updated_by`, `no_of_retakes_allowed`, and `minimum_percentage`\nfor the selected modules."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Modules updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Modules updated Successfully'
        422:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'The given data was invalid.'
                  errors:
                    module_ids:
                      - 'Please select at least one module'
                properties:
                  message:
                    type: string
                    example: 'The given data was invalid.'
                  errors:
                    type: object
                    properties:
                      module_ids:
                        type: array
                        example:
                          - 'Please select at least one module'
                        items:
                          type: string
      tags:
        - Modules
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                module_ids:
                  type: array
                  description: 'The IDs of the modules to update.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                type:
                  type: string
                  description: 'The type of module (used to determine the model class).'
                  example: quiz
                author_id:
                  type: integer
                  description: 'The new author ID to assign as `created_by`.'
                  example: 5
                noOfRetakesAllowed:
                  type: integer
                  description: 'The number of allowed retakes for the module.'
                  example: 3
                minimumPassingMarks:
                  type: integer
                  description: 'The minimum passing percentage.'
                  example: 60
              required:
                - module_ids
                - type
      security: []
  /api/modules/delete:
    post:
      summary: 'Deletes the specified modules.'
      operationId: deletesTheSpecifiedModules
      description: 'This function is responsible for deleting the selected modules. The request should contain the IDs of the modules to be deleted.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "[\n \"message\" => \"2 module(s) deleted. 1 module(s) not deleted as it is used in course(s). Please remove the modules from the course and try again.\",\n \"deletedModules\" => [1,2],\n \"notDeletedModules\" => [3],\n \"usedInCourses\" => [\n     \"module1\" => [\n         [\n             \"id\" => 1,\n             \"name\" => \"Course1\"\n         ]\n     ],\n     \"module2\" => [\n         [\n             \"id\" => 2,\n             \"name\" => \"Course2\"\n         ]\n     ]\n ]\n]"
      tags:
        - Modules
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: array
                  description: 'The IDs of all the modules which needs to be deleted.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
                type:
                  type: string
                  description: 'The type of module (used to determine the model class).'
                  example: quiz
              required:
                - delete_ids
                - type
      security: []
  /api/modules/clone:
    post:
      summary: 'Clone a module.'
      operationId: cloneAModule
      description: "Clones the module with its corresponding details and mappings.\nThe newly generated cloned module will help to let you change the content of the module with or without letting affect the real module."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module Cloned Successfully'
                properties:
                  message:
                    type: string
                    example: 'Module Cloned Successfully'
      tags:
        - Modules
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                moduleId:
                  type: integer
                  description: 'ID of the module to be cloned.'
                  example: 1
                isDeepCopy:
                  type: boolean
                  description: 'If true, content will be affected in real module if changes made in cloned module.'
                  example: false
              required:
                - moduleId
                - isDeepCopy
      security: []
  /api/quiz/lookup:
    get:
      summary: 'Quiz Lookup'
      operationId: quizLookup
      description: "Retrieves all the quiz modules. Helps while showing quiz names in form elements like dropdown.\nYou can apply filters using search_term parameter. (See Response)"
      parameters:
        -
          in: query
          name: search_term
          description: 'The name or substring of the quiz name to search for that module.'
          example: 'Final quiz'
          required: true
          schema:
            type: string
            description: 'The name or substring of the quiz name to search for that module.'
            example: 'Final quiz'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    value: 1
                    label: First-quiz
                  -
                    value: 2
                    label: Quiz-2
      tags:
        - Modules
      security: []
  /api/modules/pdf:
    get:
      summary: 'PDF Modules Tabular List'
      operationId: pDFModulesTabularList
      description: "Returns all the PDF modules in a tabular list format in paginated mode.\nYou can apply filter using search_param via moduleTypes(module type), associatedCourse(modules used in course) and moduleName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"moduleTypes": ["pdf"],associatedCourse":"","moduleName":""}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"moduleTypes": ["pdf"],associatedCourse":"","moduleName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      name: 'JavaScript Basics'
                      slug: javascript-basics
                      type: pdf
                      icon: '<i class="el-icon-document"></i>'
                      author: 'Aom Staff'
                      created_at: 'Aug 03, 2020 09:56 AM'
                      course_count: 1
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'JavaScript Basics'
                        slug: javascript-basics
                        type: pdf
                        icon: '<i class="el-icon-document"></i>'
                        author: 'Aom Staff'
                        created_at: 'Aug 03, 2020 09:56 AM'
                        course_count: 1
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'JavaScript Basics'
                        slug:
                          type: string
                          example: javascript-basics
                        type:
                          type: string
                          example: pdf
                        icon:
                          type: string
                          example: '<i class="el-icon-document"></i>'
                        author:
                          type: string
                          example: 'Aom Staff'
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        course_count:
                          type: integer
                          example: 1
      tags:
        - PDFs
      security: []
    post:
      summary: 'Create PDF Module'
      operationId: createPDFModule
      description: 'Creates a new pdf module. (See parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - PDFs
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: required
                  description: 'Name of the pdf module.'
                  example: 'Getting Started'
                content:
                  type: string
                  description: 'Content for the text modules that students will see.'
                  example: '<p>This is the updated short content here</p>'
                url:
                  type: string
                  description: 'URL or actual path of the pdf module that students will see.'
                  example: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9maWX2Rhc2hlclYw/view?usp=sharing'
                trackCompletion:
                  type: boolean
                  description: 'If true, the module is being tracked(whether its finished or not) in course player.'
                  example: true
                allowDownload:
                  type: boolean
                  description: 'If true, the pdf can be downloaded(by the learners) otherwise not in course player.'
                  example: true
                defaultZoom:
                  type: string
                  description: 'The pdf will open with the set zoom percentage in course player.'
                  example: 75%
                showSidebar:
                  type: boolean
                  description: 'If true, the pdf will open with a sidebar in course player.'
                  example: true
                categories:
                  type: array
                  description: 'Categories to be added to the module.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                estimatedCompletion:
                  type: string
                  description: 'Estimated time to complete in course player.'
                  example: '00:30:00'
                estimationCompletedUnit:
                  type: string
                  description: 'Unit of estimated time to complete in course player.'
                  example: minutes
              required:
                - content
                - url
                - trackCompletion
                - allowDownload
                - defaultZoom
      security: []
  '/api/modules/pdf/{id}':
    get:
      summary: 'Get PDF Module'
      operationId: getPDFModule
      description: "Retrieves the details of the specified pdf module. Helps in fetching pdf module using module ID. (See Parameters)\nReturns : id, name, slug, content, url, allowDownload, trackCompletion, estimatedCompletion, estimationCompletedUnit, defaultZoom, showSidebar and categories of the pdf module created."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 6
                  name: 'Getting Started'
                  slug: getting-started
                  content: ' '
                  url: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9maWX2Rhc2hlclYw/view?usp=sharing'
                  allowDownload: true
                  trackCompletion: true
                  estimatedCompletion: null
                  estimationCompletedUnit: null
                  defaultZoom: page_width
                  showSidebar: true
                  categories:
                    - 1
                    - 2
                    - 3
                properties:
                  id:
                    type: integer
                    example: 6
                  name:
                    type: string
                    example: 'Getting Started'
                  slug:
                    type: string
                    example: getting-started
                  content:
                    type: string
                    example: ' '
                  url:
                    type: string
                    example: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9maWX2Rhc2hlclYw/view?usp=sharing'
                  allowDownload:
                    type: boolean
                    example: true
                  trackCompletion:
                    type: boolean
                    example: true
                  estimatedCompletion:
                    type: string
                    example: null
                  estimationCompletedUnit:
                    type: string
                    example: null
                  defaultZoom:
                    type: string
                    example: page_width
                  showSidebar:
                    type: boolean
                    example: true
                  categories:
                    type: array
                    example:
                      - 1
                      - 2
                      - 3
                    items:
                      type: integer
      tags:
        - PDFs
      security: []
    put:
      summary: 'Update PDF Module'
      operationId: updatePDFModule
      description: "Updates the details of a specified PDF module. (See parameters)\nPDF modules can be used in the course as course content/lesson."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Module updated successfully'
      tags:
        - PDFs
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the PDF module.'
                  example: 'Getting Started'
                content:
                  type: string
                  description: 'Content for the PDF module that students will see.'
                  example: '<p>This is the updated short content here</p>'
                url:
                  type: string
                  description: 'URL or actual path of the PDF module that students will see.'
                  example: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9maWX2Rhc2hlclYw/view?usp=sharing'
                trackCompletion:
                  type: boolean
                  description: "If true, the module is being tracked (whether it's finished or not) in course player."
                  example: true
                allowDownload:
                  type: boolean
                  description: 'If true, the PDF can be downloaded (by the students) otherwise not in course player.'
                  example: true
                defaultZoom:
                  type: string
                  description: 'The PDF will open with the set zoom percentage in course player.'
                  example: 75%
                showSidebar:
                  type: boolean
                  description: 'If true, the PDF will open with a sidebar in course player.'
                  example: true
                categories:
                  type: array
                  description: 'Categories to be added to the module.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                estimatedCompletion:
                  type: string
                  description: 'Estimated time to complete in course player.'
                  example: '00:30:00'
                estimationCompletedUnit:
                  type: string
                  description: 'Unit of estimated time to complete in course player.'
                  example: minutes
              required:
                - name
                - url
                - defaultZoom
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the pdf module.'
        example: '6'
        required: true
        schema:
          type: string
  /api/module/pdf/details:
    get:
      summary: 'Get PDF Module Details'
      operationId: getPDFModuleDetails
      description: 'To get the details of a pdf module, you need to use this request. (See parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'First PDF'
                  slug: first-pdf
                  content: 'A brief description'
                  courseName: 'First Course'
                  courseSlug: 'http://localhost:8000/courses/1/launch'
                  url: 'http://localhost:8000/courses/1/modules/2/launch'
                  totalPoints: 20
                  shouldBeEvaluated: true
                  min_time_spent: 90
                  otherModules: []
                  launchCheck: {  }
                  prevSlug: first-video
                  nextSlug: second-video
                  currentUserId: 1
                  currentStudentAvatar: 'http://localhost:8000/storage/avatars/1.png'
                  currentUserName: 'John Doe'
                  status: 'In Progress'
                  statusRowId: 1
                  timeSpent: 0
                  course_newly_completed: false
                  timeToBeSpent: 1
                  instructorResponse: null
                properties:
                  name:
                    type: string
                    example: 'First PDF'
                  slug:
                    type: string
                    example: first-pdf
                  content:
                    type: string
                    example: 'A brief description'
                  courseName:
                    type: string
                    example: 'First Course'
                  courseSlug:
                    type: string
                    example: 'http://localhost:8000/courses/1/launch'
                  url:
                    type: string
                    example: 'http://localhost:8000/courses/1/modules/2/launch'
                  totalPoints:
                    type: integer
                    example: 20
                  shouldBeEvaluated:
                    type: boolean
                    example: true
                  min_time_spent:
                    type: integer
                    example: 90
                  otherModules:
                    type: array
                    example: []
                  launchCheck:
                    type: object
                    properties: {  }
                  prevSlug:
                    type: string
                    example: first-video
                  nextSlug:
                    type: string
                    example: second-video
                  currentUserId:
                    type: integer
                    example: 1
                  currentStudentAvatar:
                    type: string
                    example: 'http://localhost:8000/storage/avatars/1.png'
                  currentUserName:
                    type: string
                    example: 'John Doe'
                  status:
                    type: string
                    example: 'In Progress'
                  statusRowId:
                    type: integer
                    example: 1
                  timeSpent:
                    type: integer
                    example: 0
                  course_newly_completed:
                    type: boolean
                    example: false
                  timeToBeSpent:
                    type: integer
                    example: 1
                  instructorResponse:
                    type: string
                    example: null
      tags:
        - PDFs
      security: []
    parameters:
      -
        in: path
        name: registrationId
        description: 'ID of the course registration.'
        example: '1'
        required: true
        schema:
          type: string
      -
        in: path
        name: moduleId
        description: 'ID of the pdf module.'
        example: '2'
        required: true
        schema:
          type: string
      -
        in: path
        name: portalId
        description: 'Optional parameter. The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
        required: true
        schema:
          type: integer
        examples:
          omitted:
            summary: 'When the value is omitted'
            value: ''
          present:
            summary: 'When the value is present'
            value: 5
  /api/module/pdf/content-details:
    get:
      summary: 'Retrieve Detailed PDF module Info for Membership content'
      operationId: retrieveDetailedPDFModuleInfoForMembershipContent
      description: "Retrieves details of pdf module in depth for the same membership the current pdf module is attached to.\nReturns related fields value. (See Response)"
      parameters:
        -
          in: query
          name: moduleId
          description: 'ID of the pdf module.'
          example: '9'
          required: true
          schema:
            type: string
            description: 'ID of the pdf module.'
            example: '9'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Getting Started'
                  slug: getting-started
                  content: ' '
                  url: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9maWX2Rhc2hlclYw/view?usp=sharing'
                  canDownload: true
                  trackCompletion: true
                  defaultZoom: page_width
                  showSidebar: true
                  timeSpent: null
                properties:
                  name:
                    type: string
                    example: 'Getting Started'
                  slug:
                    type: string
                    example: getting-started
                  content:
                    type: string
                    example: ' '
                  url:
                    type: string
                    example: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9maWX2Rhc2hlclYw/view?usp=sharing'
                  canDownload:
                    type: boolean
                    example: true
                  trackCompletion:
                    type: boolean
                    example: true
                  defaultZoom:
                    type: string
                    example: page_width
                  showSidebar:
                    type: boolean
                    example: true
                  timeSpent:
                    type: string
                    example: null
      tags:
        - PDFs
      security: []
  /api/pages/layouts:
    get:
      summary: 'Retrieve Page Layouts'
      operationId: retrievePageLayouts
      description: "Retrieves all the available page layouts in list format.\nReturns the list in JSON format."
      parameters:
        -
          in: query
          name: context
          description: 'The context of the page layout. Possible values: page, section, row, or module.'
          example: sequi
          required: true
          schema:
            type: string
            description: 'The context of the page layout. Possible values: page, section, row, or module.'
            example: sequi
        -
          in: query
          name: search
          description: 'The search criteria for filtering page layouts.'
          example: []
          required: true
          schema:
            type: object
            description: 'The search criteria for filtering page layouts.'
            example: []
            properties: {  }
        -
          in: query
          name: search.title
          description: 'optional The title of the page layout to search for.'
          example: 'My Layout'
          required: false
          schema:
            type: string
            description: 'optional The title of the page layout to search for.'
            example: 'My Layout'
        -
          in: query
          name: search.category
          description: 'optional The categories to filter the page layouts by.'
          example:
            - 'category 1'
            - 'category 2'
          required: false
          schema:
            type: array
            description: 'optional The categories to filter the page layouts by.'
            example:
              - 'category 1'
              - 'category 2'
            items:
              type: string
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'Layout 1'
                  thumbnail: 'https://example.com/layout1.jpg'
                  type: predefined
                  category: 'category 1'
                  data: '<div>Layout 1 HTML</div>'
                  portal_id: 1
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'Layout 1'
                  thumbnail:
                    type: string
                    example: 'https://example.com/layout1.jpg'
                  type:
                    type: string
                    example: predefined
                  category:
                    type: string
                    example: 'category 1'
                  data:
                    type: string
                    example: '<div>Layout 1 HTML</div>'
                  portal_id:
                    type: integer
                    example: 1
      tags:
        - Pages
      security: []
    post:
      summary: 'Save Page Layout'
      operationId: savePageLayout
      description: "Saves a new page layout.\nThis endpoint is being used by users to save their created page layouts."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Layout saved successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Layout saved successfully'
      tags:
        - Pages
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the page layout.'
                  example: ea
                context:
                  type: string
                  description: 'Context of the page layout. Context options: page, section, row or module.'
                  example: earum
                data:
                  type: string
                  description: 'HTML content of the page layout.'
                  example: consequatur
                portalId:
                  type: integer
                  description: 'Portal ID of the page layout.'
                  example: 8
              required:
                - name
                - context
                - data
                - portalId
      security: []
  /api/pages/snippets:
    get:
      summary: 'Retrieve Page Snippets'
      operationId: retrievePageSnippets
      description: "Retrieves all the available page snippets in list format.\nReturns the list in JSON format."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  identifier1:
                    name: 'Snippet 1'
                    html: '<div>Snippet 1 HTML</div>'
                  identifier2:
                    name: 'Snippet 2'
                    html: '<div>Snippet 2 HTML</div>'
                properties:
                  identifier1:
                    type: object
                    properties:
                      name:
                        type: string
                        example: 'Snippet 1'
                      html:
                        type: string
                        example: '<div>Snippet 1 HTML</div>'
                  identifier2:
                    type: object
                    properties:
                      name:
                        type: string
                        example: 'Snippet 2'
                      html:
                        type: string
                        example: '<div>Snippet 2 HTML</div>'
      tags:
        - Pages
      security: []
  '/api/page/{id}':
    get:
      summary: 'Get Page'
      operationId: getPage
      description: 'Returns Page details'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  title: 'Home Page'
                  slug: ''
                  content: []
                  layout: full_width
                  seo_title: ''
                  seo_description: ''
                  seo_thumbnail_url: ''
                  restrictedToLoginUser: false
                  accessibleBy: all
                  metas: []
                  userCategory: []
                  userType: []
                properties:
                  id:
                    type: integer
                    example: 1
                  title:
                    type: string
                    example: 'Home Page'
                  slug:
                    type: string
                    example: ''
                  content:
                    type: array
                    example: []
                  layout:
                    type: string
                    example: full_width
                  seo_title:
                    type: string
                    example: ''
                  seo_description:
                    type: string
                    example: ''
                  seo_thumbnail_url:
                    type: string
                    example: ''
                  restrictedToLoginUser:
                    type: boolean
                    example: false
                  accessibleBy:
                    type: string
                    example: all
                  metas:
                    type: array
                    example: []
                  userCategory:
                    type: array
                    example: []
                  userType:
                    type: array
                    example: []
      tags:
        - Pages
      security: []
    put:
      summary: 'Update Page'
      operationId: updatePage
      description: "Updates the specified page with new data including title, content, layout,\nSEO information, and access restrictions. The function accepts the page ID\nand a request object containing the new data. Validates the request data\nbefore updating the page. If the page is restricted to logged-in users,\nit validates the access permissions and updates user categories or types\naccordingly."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Page updated successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Page updated successfully'
      tags:
        - Pages
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                title:
                  type: required
                  description: 'The title of the page.'
                  example: 'Home Page'
                content:
                  type: optional
                  description: 'The content of the page in JSON format.'
                  example: '[{"type": "text", "text": "<p>This is a sample page.</p>"}]'
                layout:
                  type: required
                  description: 'The layout type for the page. Layout options: full_width, no_header, fixed_width.'
                  example: full_width
                seo_title:
                  type: optional
                  description: 'SEO title for the page.'
                  example: 'null'
                seo_description:
                  type: optional
                  description: 'SEO description for the page.'
                  example: 'null'
                seo_thumbnail_url:
                  type: optional
                  description: 'Thumbnail image for the page.'
                  example: 'null'
                restrictedToLoginUser:
                  type: boolean
                  description: 'Indicates if the page is restricted to logged-in users.'
                  example: true
                accessibleBy:
                  type: string
                  description: 'if restrictedToLoginUser is true. The access restriction type. Options: all, user_category, user_type.'
                  example: user_category
                userCategory:
                  type: array
                  description: 'if accessibleBy is user_category. Array of user categories.'
                  example:
                    - Student
                    - Teacher
                  items:
                    type: string
                userType:
                  type: array
                  description: 'if accessibleBy is user_type. Array of user types.'
                  example:
                    - Student
                    - Teacher
                  items:
                    type: string
              required:
                - accessibleBy
                - userCategory
                - userType
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the page that needs to be retrieved.'
        example: 3
        required: true
        schema:
          type: integer
  /api/contact-form:
    post:
      summary: 'Save Contact form response'
      operationId: saveContactFormResponse
      description: "The request helps in sending contact form responses to the admins and instructors of the platform.\nGenerally this form is filled and sent by the learners to enquire something regarding your product, course or the platform."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Mail sent successfully'
                properties:
                  message:
                    type: string
                    example: 'Mail sent successfully'
      tags:
        - Pages
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                firstName:
                  type: string
                  description: 'First Name of the user.'
                  example: John
                lastName:
                  type: string
                  description: 'Last Name of the user.'
                  example: Doe
                email:
                  type: string
                  description: 'Email of the user.'
                  example: john@example.com
                phoneNo:
                  type: string
                  description: 'Phone Number of the user.'
                  example: '1234567890'
                content:
                  type: string
                  description: 'Message of the user.'
                  example: 'Question about your course?'
                toEmail:
                  type: string
                  description: 'optional Email of the recipient. If not provided, email will be sent to the admin email.'
                  example: aom-staff@example.com
              required:
                - firstName
                - lastName
                - email
                - phoneNo
                - content
      security: []
  /api/pages/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the pages in a tabular list format in paginated mode.\nYou can apply filter using search_param via pageName(page name)."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName": "name", "direction": "asc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName": "name", "direction": "asc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: 0
          required: false
          schema:
            type: integer
            description: 'for searching items based on field names.'
            example: 0
        -
          in: query
          name: type
          description: 'optional The type of pages to retrieve.'
          example: 0
          required: false
          schema:
            type: integer
            description: 'optional The type of pages to retrieve.'
            example: 0
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      title: 'Home Page'
                      slug: home-page
                      author: 'John Doe'
                      created_at: '2021-01-01 12:00:00'
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        title: 'Home Page'
                        slug: home-page
                        author: 'John Doe'
                        created_at: '2021-01-01 12:00:00'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: 'Home Page'
                        slug:
                          type: string
                          example: home-page
                        author:
                          type: string
                          example: 'John Doe'
                        created_at:
                          type: string
                          example: '2021-01-01 12:00:00'
      tags:
        - Pages
      security: []
  /api/pages/dropdownlist:
    get:
      summary: 'Dropdown List'
      operationId: dropdownList
      description: "Retrieves a list of pages with their ID and title.\nReturns the list in JSON format."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    title: 'Page 1'
                  -
                    id: 2
                    title: 'Page 2'
      tags:
        - Pages
      security: []
  /api/pages/getlearnerDasboardList:
    get:
      summary: "Get the learner's dashboard menu and accessible pages."
      operationId: getTheLearnersDashboardMenuAndAccessiblePages
      description: "This function retrieves the list of menu items for a general user and fetches pages\nthat are accessible based on restrictions (either globally or for a specific user type)."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  pages:
                    -
                      id: 1
                      title: Home
                    -
                      id: 2
                      title: Profile
                  menus:
                    -
                      id: 1
                      name: Dashboard
                      slug: dashboard
                properties:
                  pages:
                    type: array
                    example:
                      -
                        id: 1
                        title: Home
                      -
                        id: 2
                        title: Profile
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: Home
                  menus:
                    type: array
                    example:
                      -
                        id: 1
                        name: Dashboard
                        slug: dashboard
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: Dashboard
                        slug:
                          type: string
                          example: dashboard
      tags:
        - Pages
      security: []
  /api/pages/timezoneList:
    get:
      summary: 'Timezone List'
      operationId: timezoneList
      description: "Retrieves all the available PHP timezones in list format.\nReturns the list in JSON format."
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: '["Africa/Abidjan", "Africa/Accra", ..]'
      tags:
        - Pages
      security: []
  /api/pages/layout/lookup:
    get:
      summary: 'Layout Lookup'
      operationId: layoutLookup
      description: "Retrieves a list of available page layouts in key-value pairs.\nThe 'db_value' represents the layout identifier used in the database,\nand the 'display_value' provides the user-friendly name for each layout.\nReturns the list in JSON format."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: full_width
                    display_value: 'Full Width'
                  -
                    db_value: fixed_width
                    display_value: 'Fixed width with left/right margin gaps'
                  -
                    db_value: no_header
                    display_value: 'No Header/Menus/Footer'
      tags:
        - Pages
      security: []
  /api/pages/restriction/lookup:
    get:
      summary: 'Page Restriction Lookup'
      operationId: pageRestrictionLookup
      description: "Retrieves all the available page restrictions in key-value pairs.\nThe 'db_value' represents the restriction identifier used in the database,\nand the 'display_value' provides the user-friendly name for each restriction.\nReturns the list in JSON format."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: all
                    display_value: 'No Restriction'
                  -
                    db_value: user_category
                    display_value: 'Restrict by User Categories'
                  -
                    db_value: user_type
                    display_value: 'Restrict by User Types'
      tags:
        - Pages
      security: []
  /api/pages/categories/lookup:
    get:
      summary: 'Page Category Lookup'
      operationId: pageCategoryLookup
      description: "Retrieves all the page categories.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: call_to_action
                    display_value: 'Call to Action'
                  -
                    db_value: faq
                    display_value: FAQs
                  -
                    db_value: features
                    display_value: Features
                  -
                    db_value: pages
                    display_value: 'Pages '
                  -
                    db_value: products
                    display_value: 'Products '
                  -
                    db_value: team
                    display_value: Team
                  -
                    db_value: testimonial
                    display_value: Testimonial
      tags:
        - Pages
      security: []
  /api/pages:
    post:
      summary: 'Save a new Page'
      operationId: saveANewPage
      description: "Creates a new page associated with given portal.\nSaves the page restrictions.\nReturns the ID of the newly created page."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Page saved successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Page saved successfully'
      tags:
        - Pages
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                title:
                  type: required
                  description: 'The title of the page.'
                  example: 'Home Page'
                content:
                  type: optional
                  description: 'The content of the page in JSON format.'
                  example: '[{"type": "text", "text": "<p>This is a sample page.</p>"}]'
                layout:
                  type: required
                  description: 'The layout type for the page. Layout options: full_width, no_header, fixed_width.'
                  example: full_width
                seo_title:
                  type: optional
                  description: 'SEO title for the page.'
                  example: 'null'
                seo_description:
                  type: optional
                  description: 'SEO description for the page.'
                  example: 'null'
                seo_thumbnail_url:
                  type: optional
                  description: 'Thumbnail image for the page.'
                  example: 'null'
                restrictedToLoginUser:
                  type: boolean
                  description: 'to check to allow the users to access the page.'
                  example: true
                accessibleBy:
                  type: string
                  description: 'if restrictedToLoginUser is true. Accessible by options: all, user_category, user_type.'
                  example: user_category
                userCategory:
                  type: array
                  description: 'if accessibleBy is user_category. Array of user categories.'
                  example:
                    - Student
                    - Teacher
                  items:
                    type: string
                userType:
                  type: array
                  description: 'if accessibleBy is user_type. Array of user types.'
                  example:
                    - Student
                    - Teacher
                  items:
                    type: string
              required:
                - accessibleBy
                - userCategory
                - userType
      security: []
  /api/pages/delete:
    post:
      summary: 'Soft Delete Page'
      operationId: softDeletePage
      description: "To delete a page, you need to use this request. The pages will not be deleted permanently, it will be in draft mode.\nYou can restore the page later.\nReturns page drafted(if multiple selected). (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Page moved to draft successfully'
                properties:
                  message:
                    type: string
                    example: 'Page moved to draft successfully'
      tags:
        - Pages
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                page_ids:
                  type: array
                  description: 'All page IDs which needs to be drafted.'
                  example:
                    - 1
                    - 12
                    - 15
                  items:
                    type: string
              required:
                - page_ids
      security: []
  /api/pages/harddelete:
    post:
      summary: 'Hard Delete Page'
      operationId: hardDeletePage
      description: "To delete a page, you need to use this request. The pages will be deleted permanently.\nIn this case, you cannot restore the page after hard delete.\nReturns page deleted(if multiple selected). (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Pages deleted permanently'
                properties:
                  message:
                    type: string
                    example: 'Pages deleted permanently'
      tags:
        - Pages
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                page_ids:
                  type: array
                  description: 'All page IDs which needs to be deleted.'
                  example:
                    - 1
                    - 12
                    - 15
                  items:
                    type: string
              required:
                - page_ids
      security: []
  /api/pages/restore:
    post:
      summary: 'Restore Page'
      operationId: restorePage
      description: "To restore a page, you need to use this request. The pages will be restored from draft mode to published mode.\nReturns page restored(if multiple selected). (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Page restored successfully'
                properties:
                  message:
                    type: string
                    example: 'Page restored successfully'
      tags:
        - Pages
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                page_ids:
                  type: array
                  description: 'All page IDs which needs to be restored.'
                  example:
                    - 1
                    - 12
                    - 15
                  items:
                    type: string
              required:
                - page_ids
      security: []
  '/api/page/update-slug/{id}':
    put:
      summary: 'Update Page Slug'
      operationId: updatePageSlug
      description: "Updates the slug of the page identified by 'id' with the new slug provided.\nThe new slug is checked for uniqueness and if it already exists, a new slug is generated by appending a counter to the slug.\nThe updated slug is then saved to the page.\nReturns the updated slug."
      parameters:
        -
          in: query
          name: slug
          description: 'The new slug of the page.'
          example: '"about-us"'
          required: true
          schema:
            type: string
            description: 'The new slug of the page.'
            example: '"about-us"'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: string
                example: about-us-1
      tags:
        - Pages
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the page to be updated.'
        example: 3
        required: true
        schema:
          type: integer
  /api/getAnimationLookup:
    get:
      summary: 'Animation Lookup'
      operationId: animationLookup
      description: 'Retrieves all the animation classes supported by animate.css'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    label: bounce
                    value: 'animate__animated animate__bounce'
                  -
                    label: flash
                    value: 'animate__animated animate__flash'
      tags:
        - Pages
      security: []
  /api/portal:
    post:
      summary: 'Create a new portal.'
      operationId: createANewPortal
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portal created successfully'
                properties:
                  message:
                    type: string
                    example: 'Portal created successfully'
      tags:
        - Portal
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                portalName:
                  type: required
                  description: 'string The name of the portal.'
                  example: '"EduPortal"'
                portalSlug:
                  type: required
                  description: 'string The slug of the portal.'
                  example: '"eduportal"'
                totalSeat:
                  type: nullable|integer
                  description: 'The total number of seats for the portal.'
                  example: '100'
                expiryDate:
                  type: nullable|date
                  description: 'The date when the portal will expire.'
                  example: '"2023-12-31"'
                expiryMessage:
                  type: nullable|string
                  description: 'The message that will be displayed when the portal expires.'
                  example: '"This portal has expired."'
                accessPermission:
                  type: nullable|string
                  description: 'The permission for accessing the portal.'
                  example: '"all"'
                seatAccess:
                  type: nullable|string
                  description: 'The type of seat access for the portal.'
                  example: '"first-come-first-served"'
                logoImageUrl:
                  type: nullable|string
                  description: 'The URL of the logo for the portal.'
                  example: '"https://example.com/logo.png"'
                miniLogoImageUrl:
                  type: nullable|string
                  description: 'The URL of the mini logo for the portal.'
                  example: '"https://example.com/mini-logo.png"'
                brandColor:
                  type: required|string
                  description: 'The brand color for the portal.'
                  example: '"#3498db"'
                bodyBackgroundColor:
                  type: required|string
                  description: 'The background color for the body of the portal.'
                  example: '"#ffffff"'
                bodyTextColor:
                  type: required|string
                  description: 'The text color for the body of the portal.'
                  example: '"#333333"'
                headerBackgroundColor:
                  type: nullable|string
                  description: 'The background color for the header of the portal.'
                  example: '"#2c3e50"'
                selectedPrimaryLanguage:
                  type: required|string
                  description: 'The primary language for the portal.'
                  example: '"en"'
                isActive:
                  type: nullable|boolean
                  description: 'Whether the portal is active or not.'
                  example: 'true'
                selectedCourses:
                  type: nullable|array
                  description: 'The courses that should be selected for the portal.'
                  example: '[1, 2, 3]'
                selectedMembership:
                  type: nullable|integer
                  description: 'The membership that should be selected for the portal.'
                  example: '1'
                enrollMembershipId:
                  type: nullable|integer
                  description: 'The ID of the membership that should be enrolled in the portal.'
                  example: '2'
                isPortalAdminLearner:
                  type: nullable|boolean
                  description: 'Whether the portal admin is also a learner or not.'
                  example: 'false'
                portalAdminType:
                  type: nullable|string
                  description: 'The type of portal admin.'
                  example: '"super-admin"'
                addExistingUser:
                  type: nullable|array
                  description: 'The existing users that should be added to the portal.'
                  example: '[3, 4, 5]'
                selectedUsers:
                  type: nullable|array
                  description: 'The users that should be selected for the portal.'
                  example: '[1, 2]'
                selectedCategoriesIds:
                  type: nullable|array
                  description: 'The IDs of the categories that should be selected for the portal.'
                  example: '[10, 11]'
                enrollCoursesIds:
                  type: nullable|array
                  description: 'The IDs of the courses that should be enrolled in the portal.'
                  example: '[101, 102]'
                enrollLearningPathIds:
                  type: nullable|array
                  description: 'The IDs of the learning paths that should be enrolled in the portal.'
                  example: '[201, 202]'
                learnerDashboard:
                  type: nullable|integer
                  description: 'The ID of the page that should be used as the learner dashboard.'
                  example: '10'
                customStyle:
                  type: nullable|string
                  description: 'The custom CSS for the portal.'
                  example: '".portal-header { background-color: #333; }"'
                customFont:
                  type: nullable|string
                  description: 'The custom font for the portal.'
                  example: '"Arial, sans-serif"'
                customCode:
                  type: nullable|string
                  description: 'The custom code for the portal.'
                  example: '"<script>console.log(''Hello World'');</script>"'
      security: []
  /api/portal/courses:
    get:
      summary: 'Returns a list of courses for a given portal'
      operationId: returnsAListOfCoursesForAGivenPortal
      description: ''
      parameters:
        -
          in: query
          name: portalId
          description: 'The id of the portal'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The id of the portal'
            example: 1
        -
          in: query
          name: page_size
          description: 'Number of results per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'Number of results per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The current page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'JSON object specifying the column and direction to sort by.'
          example:
            column: name
            direction: asc
          required: false
          schema:
            type: object
            description: 'JSON object specifying the column and direction to sort by.'
            example:
              column: name
              direction: asc
            properties: {  }
        -
          in: query
          name: search_param
          description: 'JSON object containing search criteria.'
          example:
            name: 'John Doe'
            type: assignment
            status: Submitted
          required: false
          schema:
            type: object
            description: 'JSON object containing search criteria.'
            example:
              name: 'John Doe'
              type: assignment
              status: Submitted
            properties: {  }
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  portalName: 'portal name'
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      courseId: 1
                      portalId: 1
                      name: 'course name'
                      courseImage: 'http://localhost:8000/storage/courses/1/featured_image.jpg'
                      last24hCount: 5
                      stats:
                        notStarted: 5
                        inProgress: 0
                        completed: 0
                        total: 5
                    -
                      id: 2
                      courseId: 2
                      portalId: 2
                      name: 'course name'
                      courseImage: 'http://localhost:8000/storage/courses/2/featured_image.jpg'
                      last24hCount: 0
                      stats:
                        notStarted: 0
                        inProgress: 0
                        completed: 0
                        total: 0
                properties:
                  portalName:
                    type: string
                    example: 'portal name'
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        courseId: 1
                        portalId: 1
                        name: 'course name'
                        courseImage: 'http://localhost:8000/storage/courses/1/featured_image.jpg'
                        last24hCount: 5
                        stats:
                          notStarted: 5
                          inProgress: 0
                          completed: 0
                          total: 5
                      -
                        id: 2
                        courseId: 2
                        portalId: 2
                        name: 'course name'
                        courseImage: 'http://localhost:8000/storage/courses/2/featured_image.jpg'
                        last24hCount: 0
                        stats:
                          notStarted: 0
                          inProgress: 0
                          completed: 0
                          total: 0
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        courseId:
                          type: integer
                          example: 1
                        portalId:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'course name'
                        courseImage:
                          type: string
                          example: 'http://localhost:8000/storage/courses/1/featured_image.jpg'
                        last24hCount:
                          type: integer
                          example: 5
                        stats:
                          type: object
                          properties:
                            notStarted:
                              type: integer
                              example: 5
                            inProgress:
                              type: integer
                              example: 0
                            completed:
                              type: integer
                              example: 0
                            total:
                              type: integer
                              example: 5
      tags:
        - Portal
      security: []
  /api/portal/learningPaths:
    get:
      summary: 'Learning Path List'
      operationId: learningPathList
      description: 'Retrieves learning paths associated with the portal.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of results per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of results per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'optional The column to sort the results by.'
          example: '{"colName": "name", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'optional The column to sort the results by.'
            example: '{"colName": "name", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'optional The search query parameters.'
          example: '{"learningPathName": "Learning Path 1"}'
          required: false
          schema:
            type: string
            description: 'optional The search query parameters.'
            example: '{"learningPathName": "Learning Path 1"}'
        -
          in: query
          name: type
          description: 'The type of learning paths to retrieve.'
          example: 'all or active'
          required: true
          schema:
            type: string
            description: 'The type of learning paths to retrieve.'
            example: 'all or active'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  portalName: 'Portal 1'
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      learningPathId: 1
                      learningPathName: 'Learning Path 1'
                      learningPathImage: 'http://example.com/learning-path-image.jpg'
                      last24hCount: 5
                      learningPathStatistics:
                        notStarted: 3
                        inProgress: 2
                        completed: 5
                    -
                      learningPathId: 2
                      learningPathName: 'Learning Path 2'
                      learningPathImage: 'http://example.com/learning-path-image.jpg'
                      last24hCount: 2
                      learningPathStatistics:
                        notStarted: 1
                        inProgress: 1
                        completed: 0
                properties:
                  portalName:
                    type: string
                    example: 'Portal 1'
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        learningPathId: 1
                        learningPathName: 'Learning Path 1'
                        learningPathImage: 'http://example.com/learning-path-image.jpg'
                        last24hCount: 5
                        learningPathStatistics:
                          notStarted: 3
                          inProgress: 2
                          completed: 5
                      -
                        learningPathId: 2
                        learningPathName: 'Learning Path 2'
                        learningPathImage: 'http://example.com/learning-path-image.jpg'
                        last24hCount: 2
                        learningPathStatistics:
                          notStarted: 1
                          inProgress: 1
                          completed: 0
                    items:
                      type: object
                      properties:
                        learningPathId:
                          type: integer
                          example: 1
                        learningPathName:
                          type: string
                          example: 'Learning Path 1'
                        learningPathImage:
                          type: string
                          example: 'http://example.com/learning-path-image.jpg'
                        last24hCount:
                          type: integer
                          example: 5
                        learningPathStatistics:
                          type: object
                          properties:
                            notStarted:
                              type: integer
                              example: 3
                            inProgress:
                              type: integer
                              example: 2
                            completed:
                              type: integer
                              example: 5
      tags:
        - Portal
      security: []
    parameters:
      -
        in: path
        name: portalId
        description: 'Portal ID of the user.'
        example: '1'
        required: true
        schema:
          type: string
  /api/portal-permissions:
    get:
      summary: 'Retrieve portal admin permissions.'
      operationId: retrievePortalAdminPermissions
      description: 'Fetches a list of permissions available for portal administrators.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'Manage Users'
                  -
                    id: 2
                    name: 'Edit Content'
      tags:
        - Portal
      security: []
  /api/portal/users:
    get:
      summary: 'Retrieves a paginated and filtered list of users for a given portal, including their enrollment statistics.'
      operationId: retrievesAPaginatedAndFilteredListOfUsersForAGivenPortalIncludingTheirEnrollmentStatistics
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'Number of results per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'Number of results per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The current page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'JSON object specifying the column and direction to sort by.'
          example:
            colName: firstName
            direction: asc
          required: false
          schema:
            type: object
            description: 'JSON object specifying the column and direction to sort by.'
            example:
              colName: firstName
              direction: asc
            properties: {  }
        -
          in: query
          name: search_param
          description: 'JSON object containing search criteria.'
          example:
            nameOrEmail: 'John Doe'
          required: false
          schema:
            type: object
            description: 'JSON object containing search criteria.'
            example:
              nameOrEmail: 'John Doe'
            properties: {  }
        -
          in: query
          name: portalId
          description: 'ID of the portal to filter users.'
          example: 5
          required: true
          schema:
            type: integer
            description: 'ID of the portal to filter users.'
            example: 5
        -
          in: query
          name: userType
          description: "Type of user to filter by (e.g., 'portal_admin')."
          example: '"portal_admin"'
          required: false
          schema:
            type: string
            description: "Type of user to filter by (e.g., 'portal_admin')."
            example: '"portal_admin"'
        -
          in: query
          name: isInPortal
          description: 'Filter users who are in the portal.'
          example: true
          required: false
          schema:
            type: boolean
            description: 'Filter users who are in the portal.'
            example: true
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  portalName: 'Portal Name'
                  recordsTotal: 100
                  recordsFiltered: 10
                  recordIdsFiltered:
                    - 1
                    - 2
                    - 3
                  records:
                    -
                      id: 1
                      firstName: John
                      lastName: Doe
                      userType: learner
                      email: john.doe@example.com
                      avatar: 'https://example.com/avatar.jpg'
                      stats:
                        notStarted: 2
                        inProgress: 3
                        completed: 5
                        total: 10
                      status: active
                      lastLogin: '2 days ago'
                      createdBy: 'Admin User'
                      createdAt: '2023-10-01 12:00:00'
                      portals: 'Portal 1, Portal 2'
                      portalNameForAdmins: 'Main Portal'
                      portalUserType: portal_admin
                      is_learner: true
                      userCategory: 'Category1, Category2'
                      permissionsDisplayNames: 'View, Edit'
                      permissionsNames:
                        - view
                        - edit
                properties:
                  portalName:
                    type: string
                    example: 'Portal Name'
                  recordsTotal:
                    type: integer
                    example: 100
                  recordsFiltered:
                    type: integer
                    example: 10
                  recordIdsFiltered:
                    type: array
                    example:
                      - 1
                      - 2
                      - 3
                    items:
                      type: integer
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        firstName: John
                        lastName: Doe
                        userType: learner
                        email: john.doe@example.com
                        avatar: 'https://example.com/avatar.jpg'
                        stats:
                          notStarted: 2
                          inProgress: 3
                          completed: 5
                          total: 10
                        status: active
                        lastLogin: '2 days ago'
                        createdBy: 'Admin User'
                        createdAt: '2023-10-01 12:00:00'
                        portals: 'Portal 1, Portal 2'
                        portalNameForAdmins: 'Main Portal'
                        portalUserType: portal_admin
                        is_learner: true
                        userCategory: 'Category1, Category2'
                        permissionsDisplayNames: 'View, Edit'
                        permissionsNames:
                          - view
                          - edit
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        firstName:
                          type: string
                          example: John
                        lastName:
                          type: string
                          example: Doe
                        userType:
                          type: string
                          example: learner
                        email:
                          type: string
                          example: john.doe@example.com
                        avatar:
                          type: string
                          example: 'https://example.com/avatar.jpg'
                        stats:
                          type: object
                          properties:
                            notStarted:
                              type: integer
                              example: 2
                            inProgress:
                              type: integer
                              example: 3
                            completed:
                              type: integer
                              example: 5
                            total:
                              type: integer
                              example: 10
                        status:
                          type: string
                          example: active
                        lastLogin:
                          type: string
                          example: '2 days ago'
                        createdBy:
                          type: string
                          example: 'Admin User'
                        createdAt:
                          type: string
                          example: '2023-10-01 12:00:00'
                        portals:
                          type: string
                          example: 'Portal 1, Portal 2'
                        portalNameForAdmins:
                          type: string
                          example: 'Main Portal'
                        portalUserType:
                          type: string
                          example: portal_admin
                        is_learner:
                          type: boolean
                          example: true
                        userCategory:
                          type: string
                          example: 'Category1, Category2'
                        permissionsDisplayNames:
                          type: string
                          example: 'View, Edit'
                        permissionsNames:
                          type: array
                          example:
                            - view
                            - edit
                          items:
                            type: string
      tags:
        - Portal
      security: []
  '/api/portal/membership/courses/{id}':
    get:
      summary: 'Get courses for a given membership'
      operationId: getCoursesForAGivenMembership
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of records per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of records per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'optional The column to sort the results by.'
          example: '{"colName": "name", "direction": "asc"}'
          required: false
          schema:
            type: string
            description: 'optional The column to sort the results by.'
            example: '{"colName": "name", "direction": "asc"}'
        -
          in: query
          name: search_param
          description: 'optional The search query parameters.'
          example: '{"courseName": "Course 1"}'
          required: false
          schema:
            type: string
            description: 'optional The search query parameters.'
            example: '{"courseName": "Course 1"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      name: 'Course 1'
                      slug: course-1
                      status: active
                      display_status: Active
                      categories: 'Category 1'
                      author: 'John Doe'
                      created_at: '05 Jun 2020 12:00 PM'
                      stats:
                        total_enrolled: 5
                        total_completed: 2
                      last24hCount: 2
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Course 1'
                        slug: course-1
                        status: active
                        display_status: Active
                        categories: 'Category 1'
                        author: 'John Doe'
                        created_at: '05 Jun 2020 12:00 PM'
                        stats:
                          total_enrolled: 5
                          total_completed: 2
                        last24hCount: 2
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Course 1'
                        slug:
                          type: string
                          example: course-1
                        status:
                          type: string
                          example: active
                        display_status:
                          type: string
                          example: Active
                        categories:
                          type: string
                          example: 'Category 1'
                        author:
                          type: string
                          example: 'John Doe'
                        created_at:
                          type: string
                          example: '05 Jun 2020 12:00 PM'
                        stats:
                          type: object
                          properties:
                            total_enrolled:
                              type: integer
                              example: 5
                            total_completed:
                              type: integer
                              example: 2
                        last24hCount:
                          type: integer
                          example: 2
      tags:
        - Portal
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the portal.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/portal/membership/modules/{id}':
    get:
      summary: 'Get modules for a given membership'
      operationId: getModulesForAGivenMembership
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of records per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of records per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'optional The column to sort the results by.'
          example: '{"colName": "name", "direction": "asc"}'
          required: false
          schema:
            type: string
            description: 'optional The column to sort the results by.'
            example: '{"colName": "name", "direction": "asc"}'
        -
          in: query
          name: search_param
          description: 'optional The search query parameters.'
          example: '{"moduleName": "Module 1"}'
          required: false
          schema:
            type: string
            description: 'optional The search query parameters.'
            example: '{"moduleName": "Module 1"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      name: 'Module 1'
                      type: assignment
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Module 1'
                        type: assignment
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Module 1'
                        type:
                          type: string
                          example: assignment
      tags:
        - Portal
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the portal.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/portal/page/{id}':
    get:
      summary: 'Retrieve Page'
      operationId: retrievePage
      description: "Retrieves the details of a specified portal page by its ID. Returns the page's\nid, title, slug, content, and layout if found, otherwise returns an empty response."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  title: 'About Us'
                  slug: about-us
                  content: '<p>Welcome to our page</p>'
                  layout: full_width
                properties:
                  id:
                    type: integer
                    example: 1
                  title:
                    type: string
                    example: 'About Us'
                  slug:
                    type: string
                    example: about-us
                  content:
                    type: string
                    example: '<p>Welcome to our page</p>'
                  layout:
                    type: string
                    example: full_width
      tags:
        - Portal
      security: []
    put:
      summary: 'Update Page'
      operationId: updatePage
      description: 'Updates an existing page associated with given portal.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Page updated successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Page updated successfully'
      tags:
        - Portal
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                title:
                  type: required
                  description: 'The title of the page.'
                  example: 'Home Page'
                content:
                  type: optional
                  description: 'The content of the page in JSON format.'
                  example: '[{"type": "text", "text": "<p>This is a sample page.</p>"}]'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the portal page to retrieve.'
        example: 3
        required: true
        schema:
          type: integer
  /api/portal/pages/tabularlist:
    get:
      summary: 'Get pages for a given portal'
      operationId: getPagesForAGivenPortal
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of records per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of records per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'optional The column to sort the results by.'
          example: '{"colName": "name", "direction": "asc"}'
          required: false
          schema:
            type: string
            description: 'optional The column to sort the results by.'
            example: '{"colName": "name", "direction": "asc"}'
        -
          in: query
          name: search_param
          description: 'optional The search query parameters.'
          example: 0
          required: false
          schema:
            type: integer
            description: 'optional The search query parameters.'
            example: 0
        -
          in: query
          name: type
          description: 'optional The type of pages to retrieve.'
          example: 0
          required: false
          schema:
            type: integer
            description: 'optional The type of pages to retrieve.'
            example: 0
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      title: 'Home Page'
                      slug: home-page
                      content: 'This is the home page content'
                      author: 'John Doe'
                      created_at: '2021-01-01 12:00:00'
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        title: 'Home Page'
                        slug: home-page
                        content: 'This is the home page content'
                        author: 'John Doe'
                        created_at: '2021-01-01 12:00:00'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: 'Home Page'
                        slug:
                          type: string
                          example: home-page
                        content:
                          type: string
                          example: 'This is the home page content'
                        author:
                          type: string
                          example: 'John Doe'
                        created_at:
                          type: string
                          example: '2021-01-01 12:00:00'
      tags:
        - Portal
      security: []
    parameters:
      -
        in: path
        name: portalId
        description: 'The ID of the portal.'
        example: '1'
        required: true
        schema:
          type: string
  /api/portal/pages:
    post:
      summary: 'Save a new Portal Page'
      operationId: saveANewPortalPage
      description: "Validates and saves a new portal page with the provided title, content, and portal ID.\nThe page is associated with the user creating it.\nReturns the ID of the newly created portal page along with a success message."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Page saved successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Page saved successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                title:
                  type: string
                  description: 'The title of the portal page.'
                  example: '"Welcome Page"'
                content:
                  type: array
                  description: 'optional The content of the portal page, in JSON format.'
                  example:
                    -
                      type: text
                      text: '<p>Welcome to our portal.</p>'
                  items:
                    type: string
                portalId:
                  type: integer
                  description: 'The ID of the portal to associate the page with.'
                  example: 123
              required:
                - title
                - portalId
      security: []
  /api/portal/page/delete:
    post:
      summary: 'Soft Delete Page'
      operationId: softDeletePage
      description: "To delete a page, you need to use this request. The pages will not be deleted permanently, it will be in draft mode.\nYou can restore the page later.\nReturns page drafted(if multiple selected). (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Page moved to draft successfully'
                properties:
                  message:
                    type: string
                    example: 'Page moved to draft successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                page_ids:
                  type: array
                  description: 'All page IDs which needs to be drafted.'
                  example:
                    - 1
                    - 12
                    - 15
                  items:
                    type: string
              required:
                - page_ids
      security: []
  /api/portal/pages/harddelete:
    post:
      summary: 'Hard Delete Page'
      operationId: hardDeletePage
      description: "Permanently deletes pages specified by the provided page IDs. Once deleted, these pages cannot be restored.\nLogs the activity for each deleted page."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Pages deleted permanently'
                properties:
                  message:
                    type: string
                    example: 'Pages deleted permanently'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                page_ids:
                  type: array
                  description: 'List of page IDs to be deleted permanently.'
                  example:
                    - 1
                    - 12
                    - 15
                  items:
                    type: string
              required:
                - page_ids
      security: []
  /api/portal/pages/restore:
    post:
      summary: 'Restore Page'
      operationId: restorePage
      description: "Restores the pages from draft mode to published mode.\nLogs the activity for each restored page."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Page restored successfully'
                properties:
                  message:
                    type: string
                    example: 'Page restored successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                page_ids:
                  type: array
                  description: 'List of page IDs to be restored.'
                  example:
                    - 1
                    - 12
                    - 15
                  items:
                    type: string
              required:
                - page_ids
      security: []
  /api/portal/getPortalCourseCatalog:
    get:
      summary: 'Get Portal Course Catalog'
      operationId: getPortalCourseCatalog
      description: "Returns the list of available courses (and learning paths, if any) for a given portal and user.\nAllows optional filtering by course name and course category."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  courses:
                    -
                      courseId: 101
                      contentName: 'Effective Communication'
                      featureImage: 'https://example.com/images/comm.jpg'
                      isEnrolled: true
                      launchUrl: yourportal/course/effective-communication/launch
                      categoryIds:
                        - 2
                        - 3
                  learningPaths: []
                  categoryIds:
                    - 2
                    - 3
                properties:
                  courses:
                    type: array
                    example:
                      -
                        courseId: 101
                        contentName: 'Effective Communication'
                        featureImage: 'https://example.com/images/comm.jpg'
                        isEnrolled: true
                        launchUrl: yourportal/course/effective-communication/launch
                        categoryIds:
                          - 2
                          - 3
                    items:
                      type: object
                      properties:
                        courseId:
                          type: integer
                          example: 101
                        contentName:
                          type: string
                          example: 'Effective Communication'
                        featureImage:
                          type: string
                          example: 'https://example.com/images/comm.jpg'
                        isEnrolled:
                          type: boolean
                          example: true
                        launchUrl:
                          type: string
                          example: yourportal/course/effective-communication/launch
                        categoryIds:
                          type: array
                          example:
                            - 2
                            - 3
                          items:
                            type: integer
                  learningPaths:
                    type: array
                    example: []
                  categoryIds:
                    type: array
                    example:
                      - 2
                      - 3
                    items:
                      type: integer
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'The ID of the portal.'
                  example: 12
                userId:
                  type: integer
                  description: 'The ID of the user.'
                  example: 45
                search:
                  type: object
                  description: 'Optional search filters.'
                  example: []
                  properties:
                    contentName:
                      type: string
                      description: 'The partial or full name of the course to search for.'
                      example: '"Leadership"'
                    courseCategoryIds:
                      type: array
                      description: 'An array of course category IDs to filter by.'
                      example:
                        - 1
                        - 2
                        - 3
                      items:
                        type: string
              required:
                - portalId
                - userId
      security: []
  /api/portal/getPortalCustomDomainSettings:
    get:
      summary: 'Retrieves the portal settings'
      operationId: retrievesThePortalSettings
      description: ''
      parameters:
        -
          in: query
          name: domain
          description: 'The domain of the portal'
          example: "'example.com'"
          required: true
          schema:
            type: string
            description: 'The domain of the portal'
            example: "'example.com'"
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  portalCustomDomainEnabled: yes|no
                  verifiedDomain: yes|no
                  ipAddress: 127.0.0.1
                  enabledCustomDomain: yes|no
                properties:
                  portalCustomDomainEnabled:
                    type: string
                    example: yes|no
                  verifiedDomain:
                    type: string
                    example: yes|no
                  ipAddress:
                    type: string
                    example: 127.0.0.1
                  enabledCustomDomain:
                    type: string
                    example: yes|no
      tags:
        - Portal
      security: []
  /api/portal/enableCustomDomain:
    post:
      summary: 'Enable or disable custom domain for portals'
      operationId: enableOrDisableCustomDomainForPortals
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portal Settings Updated Successfully.'
                properties:
                  message:
                    type: string
                    example: 'Portal Settings Updated Successfully.'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                isEnabled:
                  type: boolean
                  description: 'Enable or disable custom domain for portals'
                  example: true
              required:
                - isEnabled
      security: []
  /api/portal/verifyDomain:
    get:
      summary: 'Verify the custom domain for portals'
      operationId: verifyTheCustomDomainForPortals
      description: ''
      parameters:
        -
          in: query
          name: string
          description: 'domain The custom domain to verify'
          example: id
          required: true
          schema:
            type: string
            description: 'domain The custom domain to verify'
            example: id
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: true
                  message: 'Domain Verified Successfully.'
                properties:
                  is_success:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Domain Verified Successfully.'
        404:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: false
                  message: 'Domain Verify Unsuccessfully.'
                properties:
                  is_success:
                    type: boolean
                    example: false
                  message:
                    type: string
                    example: 'Domain Verify Unsuccessfully.'
      tags:
        - Portal
      security: []
  /api/portal/users/addPortalAdmins:
    post:
      summary: 'Add Portal Admins'
      operationId: addPortalAdmins
      description: "Adds new or existing users as portal admins to the specified portal. This method handles:\n- Creating new users and assigning them admin roles.\n- Assigning existing users as admins.\n- Seat validation (restricted vs. unrestricted).\n- Permission assignment for admins.\n- Learner seat allocation sync with parent or current portal."
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portal Admin added successfully'
                properties:
                  message:
                    type: string
                    example: 'Portal Admin added successfully'
        422:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'The given data was invalid.'
                  errors:
                    availableSeats:
                      - 'The learner limit is reached. You can add only 2 learners.'
                properties:
                  message:
                    type: string
                    example: 'The given data was invalid.'
                  errors:
                    type: object
                    properties:
                      availableSeats:
                        type: array
                        example:
                          - 'The learner limit is reached. You can add only 2 learners.'
                        items:
                          type: string
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'The ID of the portal where admins will be added.'
                  example: 12
                portalAdmins:
                  type: array
                  description: 'List of new portal admin user objects (each must contain `email`, optionally `isLearner`). Required if `portalAdminType` is "newPortalAdmin".'
                  example:
                    - molestiae
                  items:
                    type: string
                portalAdminPermissions:
                  type: array
                  description: 'List of permission names to assign to portal admins.'
                  example:
                    - can_manage_courses
                    - can_edit_settings
                  items:
                    type: string
                isPortalAdminLearner:
                  type: boolean
                  description: 'Indicates if the selected users are also learners.'
                  example: true
                selectedExUsers:
                  type: array
                  description: 'List of existing user IDs to assign as portal admins. Required if `portalAdminType` is "existingUser".'
                  example:
                    - 3
                    - 4
                    - 5
                  items:
                    type: string
                portalAdminType:
                  type: string
                  description: 'The type of portal admin being added. Either `newPortalAdmin` or `existingUser`.'
                  example: newPortalAdmin
              required:
                - portalId
                - portalAdminType
      security: []
  /api/portal/users/addPortalLearners:
    post:
      summary: 'Add learners to a portal.'
      operationId: addLearnersToAPortal
      description: "This endpoint allows adding new learners to a portal either manually, via bulk import,\nor by selecting existing users. It also supports enrolling learners in courses, learning paths,\nand memberships, with proper seat availability validation and email domain blocking."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  blockedEmailDomainsmessage: 'Email or domain is blocked for user with email example@blocked.com. Please contact Admin.'
                  blockedEmails:
                    - example@blocked.com
                properties:
                  blockedEmailDomainsmessage:
                    type: string
                    example: 'Email or domain is blocked for user with email example@blocked.com. Please contact Admin.'
                  blockedEmails:
                    type: array
                    example:
                      - example@blocked.com
                    items:
                      type: string
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Learner added successfully'
                properties:
                  message:
                    type: string
                    example: 'Learner added successfully'
        422:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  availableSeats: 'The learner limit is reached. You can add only 0 new learners.'
                properties:
                  availableSeats:
                    type: string
                    example: 'The learner limit is reached. You can add only 0 new learners.'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'The ID of the portal to which learners should be added.'
                  example: 12
                learners:
                  type: array
                  description: 'Optional array of learner objects if adding manually or via bulk import.'
                  example:
                    - rerum
                  items:
                    type: string
                selectedCategoriesIds:
                  type: array
                  description: 'Optional category IDs to assign to the learners.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
                enrollCoursesIds:
                  type: array
                  description: 'Optional course IDs for enrollment.'
                  example:
                    - 101
                    - 102
                  items:
                    type: string
                enrollLearningPathIds:
                  type: array
                  description: 'Optional learning path IDs.'
                  example:
                    - 201
                    - 202
                  items:
                    type: string
                enrollMembershipId:
                  type: integer
                  description: 'Optional membership ID to assign.'
                  example: 301
                selectExistingUsers:
                  type: array
                  description: 'Optional array of existing user IDs to attach.'
                  example:
                    - 5
                    - 9
                  items:
                    type: string
                userAddedType:
                  type: string
                  description: "The method of adding users: 'addManually', 'bulkImport', or 'existingUser'."
                  example: addManually
              required:
                - portalId
                - userAddedType
      security: []
  /api/portal/users/updatePermissions:
    post:
      summary: 'Update the permissions of a portal admin'
      operationId: updateThePermissionsOfAPortalAdmin
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Permissions updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Permissions updated successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalAdminPermissions:
                  type: array
                  description: 'The permissions for the portal admin.'
                  example:
                    - ipsa
                  items:
                    type: string
              required:
                - portalAdminPermissions
      security: []
    parameters:
      -
        in: path
        name: userId
        description: 'User ID of the portal admin.'
        example: '1'
        required: true
        schema:
          type: string
      -
        in: path
        name: portalId
        description: 'Portal ID where the user is an admin.'
        example: '1'
        required: true
        schema:
          type: string
  /api/portal/users/remove:
    post:
      summary: 'Removes users from a given portal and its sub-portals based on the given user IDs and type.'
      operationId: removesUsersFromAGivenPortalAndItsSubPortalsBasedOnTheGivenUserIDsAndType
      description: ''
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portal user removed successfully'
                properties:
                  message:
                    type: string
                    example: 'Portal user removed successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                userIds:
                  type: array
                  description: 'The IDs of the users to remove from the portal.'
                  example:
                    - totam
                  items:
                    type: string
                portalId:
                  type: integer
                  description: 'The ID of the portal to remove the users from.'
                  example: 5
                type:
                  type: string
                  description: "The type of user to remove, either 'learner' or 'portal_admin'."
                  example: dolore
              required:
                - userIds
                - portalId
                - type
      security: []
  /api/portal/users/update-status:
    post:
      summary: 'Update the status of a portal user'
      operationId: updateTheStatusOfAPortalUser
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portal user status updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Portal user status updated successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                userIds:
                  type: array
                  description: 'The ids of the users'
                  example:
                    - repellat
                  items:
                    type: string
                status:
                  type: string
                  description: 'The status of the portal user'
                  example: est
              required:
                - userIds
                - status
      security: []
  '/api/portal/{portalId}':
    get:
      summary: 'Get detailed portal information.'
      operationId: getDetailedPortalInformation
      description: "This endpoint retrieves detailed information about a specific portal, including branding,\nconfiguration settings, seat usage, sub-portals, and selected content (courses, paths, memberships)."
      parameters:
        -
          in: query
          name: portalId
          description: 'The ID of the portal to retrieve.'
          example: 42
          required: true
          schema:
            type: integer
            description: 'The ID of the portal to retrieve.'
            example: 42
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 42
                  portalName: 'My Portal'
                  portalSlug: my-portal
                  parentPortalId: null
                  referralCode: ABCD1234
                  seatAccess: limited
                  accessPermission: invite_only
                  expiryMessage: 'Your access has expired.'
                  totalSeats: 100
                  totalSeatAccess: 100
                  expiryDate: 30-Dec-2025
                  logoImageUrl: 'https://cdn.example.com/logo.png'
                  miniLogoImageUrl: 'https://cdn.example.com/mini-logo.png'
                  brandColor: '#FF5733'
                  bodyBackgroundColor: '#ffffff'
                  bodyTextColor: '#000000'
                  headerBackgroundColor: '#f5f5f5'
                  selectedPrimaryLanguage: en
                  customStyle: '.custom { color: red; }'
                  customFont: Roboto
                  customCode: "<script>console.log('custom');</script>"
                  isActive: true
                  totalPortalAdmins: 5
                  totalLearner: 120
                  usedSeats: 80
                  availableSeats: 20
                  subPortalCount: 2
                  parentPortalSlug: null
                  parentPortalName: null
                  allowedEmails:
                    - user@example.com
                  portalCustomDomainEnabled: true
                  publicSelectedCourses:
                    - 101
                    - 102
                  privateSelectedCourses:
                    - 201
                    - 202
                  selectedPublicLearningPaths:
                    - 301
                    - 302
                  selectedPublicLearningPathNames:
                    - 'Beginner Path'
                    - 'Intermediate Path'
                  selectedPrivateLearningPaths:
                    - 401
                  selectedPrivateLearningPathNames:
                    - 'Advanced Path'
                  selectedPrivateMembership: 501
                  selectedPrivateMembershipName: 'Gold Membership'
                  selectedContent:
                    publicCourseIds:
                      - 101
                      - 102
                    privateCourseIds:
                      - 201
                      - 202
                    publicLearningPathIds:
                      - 301
                      - 302
                    publicLearningPathNames:
                      - 'Beginner Path'
                      - 'Intermediate Path'
                    privateLearningPathIds:
                      - 401
                    privateLearningPathNames:
                      - 'Advanced Path'
                    privateMembershipId: 501
                    privateMembershipName: 'Gold Membership'
                  learnerDashboard: dashboard
                properties:
                  id:
                    type: integer
                    example: 42
                  portalName:
                    type: string
                    example: 'My Portal'
                  portalSlug:
                    type: string
                    example: my-portal
                  parentPortalId:
                    type: string
                    example: null
                  referralCode:
                    type: string
                    example: ABCD1234
                  seatAccess:
                    type: string
                    example: limited
                  accessPermission:
                    type: string
                    example: invite_only
                  expiryMessage:
                    type: string
                    example: 'Your access has expired.'
                  totalSeats:
                    type: integer
                    example: 100
                  totalSeatAccess:
                    type: integer
                    example: 100
                  expiryDate:
                    type: string
                    example: 30-Dec-2025
                  logoImageUrl:
                    type: string
                    example: 'https://cdn.example.com/logo.png'
                  miniLogoImageUrl:
                    type: string
                    example: 'https://cdn.example.com/mini-logo.png'
                  brandColor:
                    type: string
                    example: '#FF5733'
                  bodyBackgroundColor:
                    type: string
                    example: '#ffffff'
                  bodyTextColor:
                    type: string
                    example: '#000000'
                  headerBackgroundColor:
                    type: string
                    example: '#f5f5f5'
                  selectedPrimaryLanguage:
                    type: string
                    example: en
                  customStyle:
                    type: string
                    example: '.custom { color: red; }'
                  customFont:
                    type: string
                    example: Roboto
                  customCode:
                    type: string
                    example: "<script>console.log('custom');</script>"
                  isActive:
                    type: boolean
                    example: true
                  totalPortalAdmins:
                    type: integer
                    example: 5
                  totalLearner:
                    type: integer
                    example: 120
                  usedSeats:
                    type: integer
                    example: 80
                  availableSeats:
                    type: integer
                    example: 20
                  subPortalCount:
                    type: integer
                    example: 2
                  parentPortalSlug:
                    type: string
                    example: null
                  parentPortalName:
                    type: string
                    example: null
                  allowedEmails:
                    type: array
                    example:
                      - user@example.com
                    items:
                      type: string
                  portalCustomDomainEnabled:
                    type: boolean
                    example: true
                  publicSelectedCourses:
                    type: array
                    example:
                      - 101
                      - 102
                    items:
                      type: integer
                  privateSelectedCourses:
                    type: array
                    example:
                      - 201
                      - 202
                    items:
                      type: integer
                  selectedPublicLearningPaths:
                    type: array
                    example:
                      - 301
                      - 302
                    items:
                      type: integer
                  selectedPublicLearningPathNames:
                    type: array
                    example:
                      - 'Beginner Path'
                      - 'Intermediate Path'
                    items:
                      type: string
                  selectedPrivateLearningPaths:
                    type: array
                    example:
                      - 401
                    items:
                      type: integer
                  selectedPrivateLearningPathNames:
                    type: array
                    example:
                      - 'Advanced Path'
                    items:
                      type: string
                  selectedPrivateMembership:
                    type: integer
                    example: 501
                  selectedPrivateMembershipName:
                    type: string
                    example: 'Gold Membership'
                  selectedContent:
                    type: object
                    properties:
                      publicCourseIds:
                        type: array
                        example:
                          - 101
                          - 102
                        items:
                          type: integer
                      privateCourseIds:
                        type: array
                        example:
                          - 201
                          - 202
                        items:
                          type: integer
                      publicLearningPathIds:
                        type: array
                        example:
                          - 301
                          - 302
                        items:
                          type: integer
                      publicLearningPathNames:
                        type: array
                        example:
                          - 'Beginner Path'
                          - 'Intermediate Path'
                        items:
                          type: string
                      privateLearningPathIds:
                        type: array
                        example:
                          - 401
                        items:
                          type: integer
                      privateLearningPathNames:
                        type: array
                        example:
                          - 'Advanced Path'
                        items:
                          type: string
                      privateMembershipId:
                        type: integer
                        example: 501
                      privateMembershipName:
                        type: string
                        example: 'Gold Membership'
                  learnerDashboard:
                    type: string
                    example: dashboard
        404:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portal not found.'
                properties:
                  message:
                    type: string
                    example: 'Portal not found.'
      tags:
        - Portal
      security: []
    put:
      summary: 'Update a portal'
      operationId: updateAPortal
      description: ''
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portal updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Portal updated successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalName:
                  type: string
                  description: 'The name of the portal.'
                  example: et
                portalSlug:
                  type: string
                  description: 'The slug of the portal.'
                  example: libero
                totalSeatAccess:
                  type: int|null
                  description: 'The total number of seats for the portal.'
                  example: veniam
                expiryDate:
                  type: date|null
                  description: 'The date when the portal will expire.'
                  example: officia
                expiryMessage:
                  type: string|null
                  description: 'The message to be displayed when the portal expires.'
                  example: nostrum
                accessPermission:
                  type: string|null
                  description: 'The type of access for the portal.'
                  example: ea
                seatAccess:
                  type: string|null
                  description: 'The type of seat access for the portal.'
                  example: sed
                logoImageUrl:
                  type: string|null
                  description: 'The url of the logo image for the portal.'
                  example: 'http://www.halvorson.org/laudantium-odit-sit-quas-sed-occaecati-provident'
                miniLogoImageUrl:
                  type: string|null
                  description: 'The url of the mini logo image for the portal.'
                  example: 'http://www.towne.com/voluptatem-quibusdam-reprehenderit-aut-minus-sint-et.html'
                brandColor:
                  type: string|null
                  description: 'The brand color of the portal.'
                  example: quo
                bodyBackgroundColor:
                  type: string|null
                  description: "The background color of the portal's body."
                  example: vero
                bodyTextColor:
                  type: string|null
                  description: "The text color of the portal's body."
                  example: sit
                headerBackgroundColor:
                  type: string|null
                  description: "The background color of the portal's header."
                  example: perspiciatis
                selectedPrimaryLanguage:
                  type: string|null
                  description: 'The primary language of the portal.'
                  example: delectus
                isActive:
                  type: boolean|null
                  description: 'Whether the portal is active or not.'
                  example: illo
                publicSelectedCourses:
                  type: array|null
                  description: 'The courses that are selected as public courses.'
                  example: est
                privateSelectedCourses:
                  type: array|null
                  description: 'The courses that are selected as private courses.'
                  example: iste
                selectedPublicLearningPaths:
                  type: array|null
                  description: 'The learning paths that are selected as public learning paths.'
                  example: alias
                selectedPrivateLearningPaths:
                  type: array|null
                  description: 'The learning paths that are selected as private learning paths.'
                  example: numquam
                selectedPrivateMembership:
                  type: int|null
                  description: 'The membership that is selected as private membership.'
                  example: nam
                customStyle:
                  type: string|null
                  description: 'The custom CSS for the portal.'
                  example: maiores
                customFont:
                  type: string|null
                  description: 'The custom font for the portal.'
                  example: natus
                customCode:
                  type: string|null
                  description: 'The custom code for the portal.'
                  example: laboriosam
                allowedEmails:
                  type: string|null
                  description: 'The emails that are allowed to access the portal.'
                  example: architecto
              required:
                - portalName
                - portalSlug
      security: []
  /api/portal/updateBranding:
    post:
      summary: 'Update the branding settings of a portal'
      operationId: updateTheBrandingSettingsOfAPortal
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portal branding updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Portal branding updated successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                logoImageUrl:
                  type: string
                  description: 'Logo image URL of the portal.'
                  example: 'https://example.com/logo.png'
                miniLogoImageUrl:
                  type: string
                  description: 'Mini logo image URL of the portal.'
                  example: 'https://example.com/mini-logo.png'
                brandColor:
                  type: string
                  description: 'Brand color of the portal.'
                  example: '#2e1e55'
                bodyBackgroundColor:
                  type: string
                  description: 'Body background color of the portal.'
                  example: '#f8f8f8'
                bodyTextColor:
                  type: string
                  description: 'Body text color of the portal.'
                  example: '#1b1e24'
                headerBackgroundColor:
                  type: string
                  description: 'Header background color of the portal.'
                  example: '#2e1e55'
                selectedPrimaryLanguage:
                  type: string
                  description: 'Selected primary language of the portal.'
                  example: en
                customStyle:
                  type: string
                  description: 'Custom CSS for the portal.'
                  example: 'CSS code'
                customCode:
                  type: string
                  description: 'Custom JavaScript code for the portal.'
                  example: 'JavaScript code'
                customFont:
                  type: string
                  description: 'Custom font for the portal.'
                  example: 'font family name'
                learnerDashboard:
                  type: string
                  description: 'JSON object for learner dashboard.'
                  example: '{"type": "page", "id": 1} or {"type": "menu", "id": "menu-name"}'
              required:
                - logoImageUrl
                - miniLogoImageUrl
                - brandColor
                - bodyBackgroundColor
                - bodyTextColor
                - headerBackgroundColor
                - selectedPrimaryLanguage
                - customStyle
                - customCode
                - customFont
                - learnerDashboard
      security: []
    parameters:
      -
        in: path
        name: portalId
        description: 'Portal ID of the user.'
        example: '1'
        required: true
        schema:
          type: string
  /api/portal/addSubPortals:
    post:
      summary: 'Add a sub portal to the given portal'
      operationId: addASubPortalToTheGivenPortal
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Sub Portal added successfully'
                properties:
                  message:
                    type: string
                    example: 'Sub Portal added successfully'
      tags:
        - Portal
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                subPortal:
                  type: required
                  description: 'An array of sub portals.'
                  example: '[{"name": "Sub Portal 1", "referralCode": "sp1"}, {"name": "Sub Portal 2", "referralCode": "sp2"}]'
      security: []
    parameters:
      -
        in: path
        name: portalId
        description: 'Portal ID of the user.'
        example: '1'
        required: true
        schema:
          type: string
  /api/portal/delete:
    post:
      summary: 'Delete a portal'
      operationId: deleteAPortal
      description: ''
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portal deleted successfully'
                properties:
                  message:
                    type: string
                    example: 'Portal deleted successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'The ID of the portal.'
                  example: 5
              required:
                - portalId
      security: []
  /api/portal/sub-portal-delete:
    post:
      summary: 'Delete multiple sub portals'
      operationId: deleteMultipleSubPortals
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Sub Portals deleted successfully'
                properties:
                  message:
                    type: string
                    example: 'Sub Portals deleted successfully'
      tags:
        - Portal
      security: []
    parameters:
      -
        in: path
        name: ids
        description: 'Comma separated sub portal IDs.'
        example: '1,2,3'
        required: true
        schema:
          type: string
      -
        in: path
        name: portalId
        description: 'The parent portal ID.'
        example: '1'
        required: true
        schema:
          type: string
  /api/portal/menus:
    post:
      summary: "Save the menu items for the given portal. The menu items should be an\narray of objects with the following properties:"
      operationId: saveTheMenuItemsForTheGivenPortalTheMenuItemsShouldBeAnarrayOfObjectsWithTheFollowingProperties
      description: "- id: The ID of the menu item.\n- label: The label to display for the menu item.\n- icon: The icon to display for the menu item.\n- type: The type of the menu item. Can be \"page\" or \"custom_link\".\n- page_id: The ID of the page if the type is \"page\".\n- custom_link: The link to redirect to if the type is \"custom_link\".\n- css_class: The CSS class to apply to the menu item.\n- level: The level of the menu item.\n- items: An array of submenu items."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Menu updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Menu updated successfully'
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Invalid request. Portal ID is required.'
                properties:
                  message:
                    type: string
                    example: 'Invalid request. Portal ID is required.'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'The ID of the portal.'
                  example: 123
                menuList:
                  type: array
                  description: 'An array of menu items.'
                  example:
                    - voluptatum
                  items:
                    type: string
              required:
                - portalId
                - menuList
      security: []
  /api/portal/users/addToLearner:
    post:
      summary: 'Add users to learner list of the portal.'
      operationId: addUsersToLearnerListOfThePortal
      description: ''
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'User updated successfully'
                properties:
                  message:
                    type: string
                    example: 'User updated successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                userIds:
                  type: array
                  description: 'The IDs of the users to add to learner list.'
                  example:
                    - similique
                  items:
                    type: string
                portalId:
                  type: integer
                  description: 'The ID of the portal to add users to.'
                  example: 17
              required:
                - userIds
                - portalId
      security: []
  /api/portal/users/updateToPortalAdmin:
    post:
      summary: 'Update a user to portal admin'
      operationId: updateAUserToPortalAdmin
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'User updated successfully'
                properties:
                  message:
                    type: string
                    example: 'User updated successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                userId:
                  type: integer
                  description: 'The id of the user'
                  example: 19
                portalId:
                  type: integer
                  description: 'The id of the portal'
                  example: 1
                portalAdminPermissions:
                  type: array
                  description: 'The permissions for the portal admin'
                  example:
                    - distinctio
                  items:
                    type: string
              required:
                - userId
                - portalId
                - portalAdminPermissions
      security: []
  /api/portal/updatePortalStatus:
    post:
      summary: 'Update the status of a given portal(s)'
      operationId: updateTheStatusOfAGivenPortals
      description: ''
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Status updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Status updated successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                ids:
                  type: array
                  description: 'The IDs of the portals to update.'
                  example:
                    - illum
                  items:
                    type: string
                status:
                  type: string
                  description: "The status to set for the portals. Options: 'Active', 'InActive'."
                  example: earum
              required:
                - ids
                - status
      security: []
  /api/portals/tabularlist:
    get:
      summary: 'Retrieve a paginated list of portals in a tabular format.'
      operationId: retrieveAPaginatedListOfPortalsInATabularFormat
      description: "Fetches portals with optional filtering by status and portal name,\nand returns the results in a paginated format with sorting options.\nThe function also provides the total and filtered records count."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of items per page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of items per page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'Optional JSON for sorting.'
          example: '{"colName":"created_at", "direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'Optional JSON for sorting.'
            example: '{"colName":"created_at", "direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'Optional JSON for filtering.'
          example: '{"status":"active", "portalName":"Example Portal"}'
          required: false
          schema:
            type: string
            description: 'Optional JSON for filtering.'
            example: '{"status":"active", "portalName":"Example Portal"}'
        -
          in: query
          name: portalId
          description: 'Optional The parent portal ID for filtering sub-portals.'
          example: velit
          required: false
          schema:
            type: string
            description: 'Optional The parent portal ID for filtering sub-portals.'
            example: velit
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 100
                  recordsFiltered: 20
                  records:
                    -
                      id: 1
                      name: 'Portal Name'
                      parentPortalId: 'Parent Portal'
                      referralCode: ABC123
                      totalSeat: 50
                      usedSeat: 25
                      seatAccess: full
                      status: active
                      slug: portal-name
                      portalAdmins: 'Admin Name'
                      portalAdminsCount: 3
                      created_by: 'Creator Name'
                      created_at: 'Sep 10, 2023 10:00 AM'
                      totalLearner: 10
                properties:
                  recordsTotal:
                    type: integer
                    example: 100
                  recordsFiltered:
                    type: integer
                    example: 20
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Portal Name'
                        parentPortalId: 'Parent Portal'
                        referralCode: ABC123
                        totalSeat: 50
                        usedSeat: 25
                        seatAccess: full
                        status: active
                        slug: portal-name
                        portalAdmins: 'Admin Name'
                        portalAdminsCount: 3
                        created_by: 'Creator Name'
                        created_at: 'Sep 10, 2023 10:00 AM'
                        totalLearner: 10
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Portal Name'
                        parentPortalId:
                          type: string
                          example: 'Parent Portal'
                        referralCode:
                          type: string
                          example: ABC123
                        totalSeat:
                          type: integer
                          example: 50
                        usedSeat:
                          type: integer
                          example: 25
                        seatAccess:
                          type: string
                          example: full
                        status:
                          type: string
                          example: active
                        slug:
                          type: string
                          example: portal-name
                        portalAdmins:
                          type: string
                          example: 'Admin Name'
                        portalAdminsCount:
                          type: integer
                          example: 3
                        created_by:
                          type: string
                          example: 'Creator Name'
                        created_at:
                          type: string
                          example: 'Sep 10, 2023 10:00 AM'
                        totalLearner:
                          type: integer
                          example: 10
      tags:
        - Portal
      security: []
  /api/portals/lookup:
    get:
      summary: 'Lookup Portals'
      operationId: lookupPortals
      description: "Retrieves portals based on the specified type, portal ID, and search term. If the portal ID is provided and not -1,\nit fetches sub-portals or reports/portals based on the type. If a search term is provided, it filters portals by name.\nReturns a list of portals with their ID, name, total seats, used seats, and available seats."
      parameters:
        -
          in: query
          name: type
          description: 'The type of lookup to perform (e.g., subPortals, reports, portals).'
          example: subPortals
          required: false
          schema:
            type: string
            description: 'The type of lookup to perform (e.g., subPortals, reports, portals).'
            example: subPortals
        -
          in: query
          name: portalId
          description: 'The portal ID to filter by (use -1 to skip filtering).'
          example: 5
          required: false
          schema:
            type: integer
            description: 'The portal ID to filter by (use -1 to skip filtering).'
            example: 5
        -
          in: query
          name: search_term
          description: 'The search term to filter portals by name.'
          example: 'Portal 1'
          required: false
          schema:
            type: string
            description: 'The search term to filter portals by name.'
            example: 'Portal 1'
        -
          in: query
          name: user_id
          description: 'The ID of the user performing the lookup.'
          example: 1
          required: false
          schema:
            type: integer
            description: 'The ID of the user performing the lookup.'
            example: 1
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'Portal 1'
                    totalSeats: 100
                    usedSeat: 50
                    availableSeats: 50
      tags:
        - Portal
      security: []
  /api/portals/menus/list:
    get:
      summary: 'Retrieves all the menus with all its associated items'
      operationId: retrievesAllTheMenusWithAllItsAssociatedItems
      description: ''
      parameters:
        -
          in: query
          name: portalId
          description: 'The portal ID to filter menus by.'
          example: 1
          required: false
          schema:
            type: integer
            description: 'The portal ID to filter menus by.'
            example: 1
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    name: 'Main Menu'
                    items:
                      -
                        label: Home
                        type: page
                        custom_link: null
                        page_id: 1
                        display_order: 1
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: /
                      -
                        label: Courses
                        type: page
                        custom_link: null
                        page_id: 2
                        display_order: 2
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: 'http://localhost:8000/course-catalog'
                      -
                        label: 'Our Team'
                        type: page
                        custom_link: null
                        page_id: 3
                        display_order: 3
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: 'http://localhost:8000/about-us'
                      -
                        label: 'Contact Us'
                        type: page
                        custom_link: null
                        page_id: 6
                        display_order: 4
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: 'http://localhost:8000/contact-us'
                  -
                    id: 2
                    name: 'Top Bar Menu'
                    items:
                      -
                        label: Dashboard
                        type: custom_link
                        custom_link: /dashboard
                        page_id: null
                        display_order: 1
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: /dashboard
                      -
                        label: Cart
                        type: page
                        custom_link: null
                        page_id: 5
                        display_order: 2
                        css_class: null
                        restrictions: null
                        open_in_new_tab: false
                        level: 1
                        isCollapsed: true
                        hyperlink: 'http://localhost:8000/cart'
                  -
                    id: 3
                    name: 'Footer Menu'
                    items: []
      tags:
        - Portal
      security: []
  '/api/admin/permissions/{id}':
    get:
      summary: 'Get the permissions of a portal admin'
      operationId: getThePermissionsOfAPortalAdmin
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n \"portalUsers\": [\n     {\n         \"portalId\": 1,\n         \"portalName\": \"Portal 1\",\n         \"permissions\": [\n             \"manage_course\",\n             \"manage_learning_path\",\n         ]\n     }\n ]\n}"
      tags:
        - Portal
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'User ID of the portal admin.'
        example: '1'
        required: true
        schema:
          type: string
  /api/portals/pages/dropdownlist:
    get:
      summary: 'Page dropdown list'
      operationId: pageDropdownList
      description: "Returns a list of pages of the associated portal with their ID and Name based on the provided portal ID and search term.\nIf a valid portal ID is provided, it filters pages associated with the portal.\nIf no portal ID or an invalid one (e.g., -1) is given, it returns all pages."
      parameters:
        -
          in: query
          name: portalId
          description: 'The portal ID to filter pages by portal. Use -1 to skip portal filtering.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'The portal ID to filter pages by portal. Use -1 to skip portal filtering.'
            example: 5
        -
          in: query
          name: search_term
          description: 'The search term to filter pages by title.'
          example: '"Advanced"'
          required: false
          schema:
            type: string
            description: 'The search term to filter pages by title.'
            example: '"Advanced"'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    title: 'Page 1'
                  -
                    id: 2
                    title: 'Page 2'
      tags:
        - Portal
      security: []
  /api/portals/pages/getPortalLearnerPagesMenu:
    get:
      summary: 'Retrieve the menu and pages for a specific portal.'
      operationId: retrieveTheMenuAndPagesForASpecificPortal
      description: "This endpoint retrieves the list of pages associated with a given portal\nand the sidebar menu items for the portal user."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  pages:
                    -
                      id: 1
                      title: 'Home Page'
                    -
                      id: 2
                      title: 'About Us'
                  menus:
                    - Dashboard
                    - 'My Profile'
                    - Settings
                properties:
                  pages:
                    type: array
                    example:
                      -
                        id: 1
                        title: 'Home Page'
                      -
                        id: 2
                        title: 'About Us'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: 'Home Page'
                  menus:
                    type: array
                    example:
                      - Dashboard
                      - 'My Profile'
                      - Settings
                    items:
                      type: string
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Invalid request. Portal ID is required.'
                properties:
                  message:
                    type: string
                    example: 'Invalid request. Portal ID is required.'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'The ID of the portal.'
                  example: 123
              required:
                - portalId
      security: []
  /api/portals/checkout:
    get:
      summary: 'Retrieve checkout details for a portal order'
      operationId: retrieveCheckoutDetailsForAPortalOrder
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recurringItems: []
                  hasSubscriptionWithFreeTrial: false
                  hasSubscriptionProduct: false
                  productDetails: []
                  totalTax: 0
                  conditions: []
                  taxRates: []
                  taxSettings: {  }
                  total: 0
                  subtotal: 0
                  itemQuantity: 1
                  portalId: 1
                  currentPortalSeats: 0
                  cartErrors:
                    message: null
                    portalMessages: null
                properties:
                  recurringItems:
                    type: array
                    example: []
                  hasSubscriptionWithFreeTrial:
                    type: boolean
                    example: false
                  hasSubscriptionProduct:
                    type: boolean
                    example: false
                  productDetails:
                    type: array
                    example: []
                  totalTax:
                    type: integer
                    example: 0
                  conditions:
                    type: array
                    example: []
                  taxRates:
                    type: array
                    example: []
                  taxSettings:
                    type: object
                    properties: {  }
                  total:
                    type: integer
                    example: 0
                  subtotal:
                    type: integer
                    example: 0
                  itemQuantity:
                    type: integer
                    example: 1
                  portalId:
                    type: integer
                    example: 1
                  currentPortalSeats:
                    type: integer
                    example: 0
                  cartErrors:
                    type: object
                    properties:
                      message:
                        type: string
                        example: null
                      portalMessages:
                        type: string
                        example: null
      tags:
        - Portal
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: required
                  description: 'The ID of the portal.'
                  example: dolore
                qty:
                  type: required
                  description: 'The quantity of the product to be purchased.'
                  example: laboriosam
                billingAddress:
                  type: required
                  description: 'The customer billing address.'
                  example: dolorum
                shippingAddress:
                  type: required
                  description: 'The customer shipping address.'
                  example: sunt
                selectedBillingAddress:
                  type: required
                  description: 'The customer selected billing address.'
                  example: tempore
                selectedShippingAddress:
                  type: required
                  description: 'The customer selected shipping address.'
                  example: animi
                isShippingSameAsBilling:
                  type: required
                  description: 'Whether the shipping address is the same as the billing address.'
                  example: in
                shippingMethodId:
                  type: required
                  description: 'The ID of the shipping method.'
                  example: aliquid
      security: []
  /api/portal/users/updateCurrentPortal:
    put:
      summary: 'Updates the current portal for a user'
      operationId: updatesTheCurrentPortalForAUser
      description: ''
      parameters:
        -
          in: query
          name: portalId
          description: 'ID of the portal to set as current.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'ID of the portal to set as current.'
            example: 1
        -
          in: query
          name: userId
          description: 'optional ID of the user to update the current portal for. Defaults to the ID of the authenticated user.'
          example: 1
          required: false
          schema:
            type: integer
            description: 'optional ID of the user to update the current portal for. Defaults to the ID of the authenticated user.'
            example: 1
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Current portal updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Current portal updated successfully'
      tags:
        - Portal
      security: []
  /api/portals/details/report:
    get:
      summary: 'Retrieve Portal Details Report'
      operationId: retrievePortalDetailsReport
      description: 'Provides detailed report information for portals based on the specified parameters.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of results per page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of results per page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'optional The column to sort the results by in the format {"colName": "name", "direction": "asc"}'
          example: doloremque
          required: false
          schema:
            type: string
            description: 'optional The column to sort the results by in the format {"colName": "name", "direction": "asc"}'
            example: doloremque
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 100
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      name: 'Portal 1'
                      parentPortalName: 'Parent Portal'
                      totalSeat: 100
                      usedSeat: 50
                      status: active
                      seatAccess: open
                      portalUserIds:
                        - 1
                        - 2
                        - 3
                      portalAdminsCount: 2
                      created_by: 'Admin User'
                      created_at: '2023-01-01 12:00:00'
                      portalExpireOn: '2024-01-01 12:00:00'
                      totalLearner: 50
                      portalUserDetails:
                        -
                          email: user1@example.com
                          firstName: John
                          lastName: Doe
                          isLearner: true
                          isAdmin: admin
                properties:
                  recordsTotal:
                    type: integer
                    example: 100
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Portal 1'
                        parentPortalName: 'Parent Portal'
                        totalSeat: 100
                        usedSeat: 50
                        status: active
                        seatAccess: open
                        portalUserIds:
                          - 1
                          - 2
                          - 3
                        portalAdminsCount: 2
                        created_by: 'Admin User'
                        created_at: '2023-01-01 12:00:00'
                        portalExpireOn: '2024-01-01 12:00:00'
                        totalLearner: 50
                        portalUserDetails:
                          -
                            email: user1@example.com
                            firstName: John
                            lastName: Doe
                            isLearner: true
                            isAdmin: admin
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Portal 1'
                        parentPortalName:
                          type: string
                          example: 'Parent Portal'
                        totalSeat:
                          type: integer
                          example: 100
                        usedSeat:
                          type: integer
                          example: 50
                        status:
                          type: string
                          example: active
                        seatAccess:
                          type: string
                          example: open
                        portalUserIds:
                          type: array
                          example:
                            - 1
                            - 2
                            - 3
                          items:
                            type: integer
                        portalAdminsCount:
                          type: integer
                          example: 2
                        created_by:
                          type: string
                          example: 'Admin User'
                        created_at:
                          type: string
                          example: '2023-01-01 12:00:00'
                        portalExpireOn:
                          type: string
                          example: '2024-01-01 12:00:00'
                        totalLearner:
                          type: integer
                          example: 50
                        portalUserDetails:
                          type: array
                          example:
                            -
                              email: user1@example.com
                              firstName: John
                              lastName: Doe
                              isLearner: true
                              isAdmin: admin
                          items:
                            type: object
                            properties:
                              email:
                                type: string
                                example: user1@example.com
                              firstName:
                                type: string
                                example: John
                              lastName:
                                type: string
                                example: Doe
                              isLearner:
                                type: boolean
                                example: true
                              isAdmin:
                                type: string
                                example: admin
      tags:
        - Portal
      security: []
  /api/portal/clone:
    post:
      summary: 'Clone a portal and optionally its sub-portal.'
      operationId: cloneAPortalAndOptionallyItsSubPortal
      description: "This endpoint clones a portal and its associated data (such as branding, settings, etc.),\nincluding an optional sub-portal. A new referral code is generated for each cloned portal."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Portal Cloned Successfully'
                properties:
                  message:
                    type: string
                    example: 'Portal Cloned Successfully'
      tags:
        - Portal
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                portalId:
                  type: integer
                  description: 'The ID of the portal to be cloned.'
                  example: 5
                portalName:
                  type: string
                  description: 'The name of the new cloned portal.'
                  example: 'My Cloned Portal'
                subPortals:
                  type: boolean
                  description: 'Optional flag indicating whether to clone a sub-portal.'
                  example: true
              required:
                - portalId
                - portalName
      security: []
  /api/modules/powerpoint:
    get:
      summary: 'Powerpoint Modules Tabular List'
      operationId: powerpointModulesTabularList
      description: "Returns all the powerpoint modules in a tabular list format with pagination.\nFilters can be applied using search parameters such as moduleCategoryIds,\nassociatedCourse, and moduleName. Data can be sorted using order_by."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of items per page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of items per page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number for pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number for pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'Optional JSON for sorting items by column.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'Optional JSON for sorting items by column.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'Optional JSON for searching by moduleCategoryIds, associatedCourse, and moduleName.'
          example: '{"moduleCategoryIds": [], "associatedCourse": "", "moduleName": ""}'
          required: false
          schema:
            type: string
            description: 'Optional JSON for searching by moduleCategoryIds, associatedCourse, and moduleName.'
            example: '{"moduleCategoryIds": [], "associatedCourse": "", "moduleName": ""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 5
                  records:
                    -
                      id: 1
                      name: 'Powerpoint Module 1'
                      slug: powerpoint-module-1
                      type: powerpoint
                      icon: '<i class="el-icon-presentation"></i>'
                      author: 'John Doe'
                      showMappedCourses: false
                      created_at: 'Aug 03, 2020 09:56 AM'
                      course_count: 2
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 5
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Powerpoint Module 1'
                        slug: powerpoint-module-1
                        type: powerpoint
                        icon: '<i class="el-icon-presentation"></i>'
                        author: 'John Doe'
                        showMappedCourses: false
                        created_at: 'Aug 03, 2020 09:56 AM'
                        course_count: 2
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Powerpoint Module 1'
                        slug:
                          type: string
                          example: powerpoint-module-1
                        type:
                          type: string
                          example: powerpoint
                        icon:
                          type: string
                          example: '<i class="el-icon-presentation"></i>'
                        author:
                          type: string
                          example: 'John Doe'
                        showMappedCourses:
                          type: boolean
                          example: false
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        course_count:
                          type: integer
                          example: 2
      tags:
        - Powerpoint
      security: []
    post:
      summary: 'Create a new Powerpoint module'
      operationId: createANewPowerpointModule
      description: 'Creates a new Powerpoint module. Returns the ID of the newly created module.'
      parameters:
        -
          in: query
          name: name
          description: 'Name of the Powerpoint module.'
          example: 'Getting Started'
          required: true
          schema:
            type: string
            description: 'Name of the Powerpoint module.'
            example: 'Getting Started'
        -
          in: query
          name: viewer
          description: 'microsoft_office, google_viewer.'
          example: microsoft_office
          required: true
          schema:
            type: string
            description: 'microsoft_office, google_viewer.'
            example: microsoft_office
        -
          in: query
          name: content
          description: 'Content for the text modules that students will see.'
          example: '<p>This is the content for the module</p>'
          required: false
          schema:
            type: string
            description: 'Content for the text modules that students will see.'
            example: '<p>This is the content for the module</p>'
        -
          in: query
          name: url
          description: 'URL or actual path of the Powerpoint module that students will see.'
          example: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9ma2Rhc2hlclYw/view?usp=sharing'
          required: true
          schema:
            type: string
            description: 'URL or actual path of the Powerpoint module that students will see.'
            example: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9ma2Rhc2hlclYw/view?usp=sharing'
        -
          in: query
          name: estimatedCompletion
          description: 'Estimated time in minutes that a student should take to complete this module.'
          example: 30
          required: false
          schema:
            type: integer
            description: 'Estimated time in minutes that a student should take to complete this module.'
            example: 30
        -
          in: query
          name: estimationCompletedUnit
          description: 'Required if estimatedCompletion is set.'
          example: hour
          required: false
          schema:
            type: string
            description: 'Required if estimatedCompletion is set.'
            example: hour
        -
          in: query
          name: categories
          description: 'of integers or strings List of categories that this module belongs to. If strings are provided, new categories will be created.'
          example:
            - 1
            - 2
            - 3
            - 'Category 1'
          required: false
          schema:
            type: array
            description: 'of integers or strings List of categories that this module belongs to. If strings are provided, new categories will be created.'
            example:
              - 1
              - 2
              - 3
              - 'Category 1'
            items:
              type: string
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 6
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 6
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - Powerpoint
      security: []
  '/api/modules/powerpoint/{id}':
    get:
      summary: 'Retrieve a Powerpoint Module'
      operationId: retrieveAPowerpointModule
      description: 'Retrieves a Powerpoint module by given id. Returns its details and associated courses.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 6
                  name: 'Getting Started'
                  slug: getting-started
                  content: '<p>This is the content for the module</p>'
                  url: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9ma2Rhc2hlclYw/view?usp=sharing'
                  estimatedCompletion: 1
                  estimationCompletedUnit: hour
                  categories:
                    - 1
                    - 2
                  courses:
                    -
                      course_id: 1
                      course_name: 'Course 1'
                    -
                      course_id: 2
                      course_name: 'Course 2'
                properties:
                  id:
                    type: integer
                    example: 6
                  name:
                    type: string
                    example: 'Getting Started'
                  slug:
                    type: string
                    example: getting-started
                  content:
                    type: string
                    example: '<p>This is the content for the module</p>'
                  url:
                    type: string
                    example: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9ma2Rhc2hlclYw/view?usp=sharing'
                  estimatedCompletion:
                    type: integer
                    example: 1
                  estimationCompletedUnit:
                    type: string
                    example: hour
                  categories:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  courses:
                    type: array
                    example:
                      -
                        course_id: 1
                        course_name: 'Course 1'
                      -
                        course_id: 2
                        course_name: 'Course 2'
                    items:
                      type: object
                      properties:
                        course_id:
                          type: integer
                          example: 1
                        course_name:
                          type: string
                          example: 'Course 1'
      tags:
        - Powerpoint
      security: []
    put:
      summary: 'Update Powerpoint Module'
      operationId: updatePowerpointModule
      description: "Updates the details of the specified powerpoint module. (See parameters)\nPowerpoint modules can be used in the course as course content/lesson.\n\nReturns : successfull message"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Module updated successfully'
      tags:
        - Powerpoint
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'The ID of the powerpoint module.'
                  example: '6'
                viewer:
                  type: required
                  description: 'Viewer for the module.'
                  example: '<iframe src="https://view.officeapps.live.com/op/embed.aspx?src=https://example.com/powerpoint.pptx" width="100%" height="600px"></iframe>'
                name:
                  type: string
                  description: 'Name of the powerpoint module.'
                  example: My-powerpoint-lesson
                content:
                  type: string
                  description: 'Content for the powerpoint modules that students will see.'
                  example: '<p>This is the content for the module</p>'
                url:
                  type: string
                  description: 'URL or actual path of the powerpoint module that students will see.'
                  example: 'https://drive.google.com/file/d/0B5cbJMbHsJ1gc3RhcnRlcl9ma2Rhc2hlclYw/view?usp=sharing'
                estimatedCompletion:
                  type: integer
                  description: 'Estimated time in minutes that a student should take to complete this module.'
                  example: 30
                estimationCompletedUnit:
                  type: string
                  description: 'Required if estimatedCompletion is set.'
                  example: hour
                categories:
                  type: array
                  description: 'of integers or strings List of categories that this module belongs to. If strings are provided, new categories will be created.'
                  example:
                    - 1
                    - 2
                    - 3
                    - 'Category 1'
                  items:
                    type: string
              required:
                - name
                - content
                - url
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the Powerpoint module.'
        example: '6'
        required: true
        schema:
          type: string
  /api/module/powerpoint/details:
    get:
      summary: 'Get Powerpoint Module Details'
      operationId: getPowerpointModuleDetails
      description: 'To get the details of a powerpoint module, you need to use this request. (See parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'First Powerpoint'
                  slug: first-powerpoint
                  content: 'A brief description'
                  courseName: 'First Course'
                  courseSlug: 'http://localhost:8000/courses/1/launch'
                  url: 'http://localhost:8000/courses/1/modules/2/launch'
                  totalPoints: 20
                  shouldBeEvaluated: true
                  min_time_spent: 90
                  otherModules: []
                  launchCheck: {  }
                  prevSlug: first-video
                  nextSlug: second-video
                  currentUserId: 1
                  currentStudentAvatar: 'http://localhost:8000/storage/avatars/1.png'
                  currentUserName: 'John Doe'
                  status: 'In Progress'
                  statusRowId: 1
                  timeSpent: 0
                  course_newly_completed: false
                  timeToBeSpent: 1
                  instructorResponse: null
                properties:
                  name:
                    type: string
                    example: 'First Powerpoint'
                  slug:
                    type: string
                    example: first-powerpoint
                  content:
                    type: string
                    example: 'A brief description'
                  courseName:
                    type: string
                    example: 'First Course'
                  courseSlug:
                    type: string
                    example: 'http://localhost:8000/courses/1/launch'
                  url:
                    type: string
                    example: 'http://localhost:8000/courses/1/modules/2/launch'
                  totalPoints:
                    type: integer
                    example: 20
                  shouldBeEvaluated:
                    type: boolean
                    example: true
                  min_time_spent:
                    type: integer
                    example: 90
                  otherModules:
                    type: array
                    example: []
                  launchCheck:
                    type: object
                    properties: {  }
                  prevSlug:
                    type: string
                    example: first-video
                  nextSlug:
                    type: string
                    example: second-video
                  currentUserId:
                    type: integer
                    example: 1
                  currentStudentAvatar:
                    type: string
                    example: 'http://localhost:8000/storage/avatars/1.png'
                  currentUserName:
                    type: string
                    example: 'John Doe'
                  status:
                    type: string
                    example: 'In Progress'
                  statusRowId:
                    type: integer
                    example: 1
                  timeSpent:
                    type: integer
                    example: 0
                  course_newly_completed:
                    type: boolean
                    example: false
                  timeToBeSpent:
                    type: integer
                    example: 1
                  instructorResponse:
                    type: string
                    example: null
      tags:
        - Powerpoint
      security: []
    parameters:
      -
        in: path
        name: registrationId
        description: 'ID of the course registration.'
        example: '1'
        required: true
        schema:
          type: string
      -
        in: path
        name: moduleId
        description: 'ID of the powerpoint module.'
        example: '2'
        required: true
        schema:
          type: string
      -
        in: path
        name: portalId
        description: 'Optional parameter. The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
        required: true
        schema:
          type: integer
        examples:
          omitted:
            summary: 'When the value is omitted'
            value: ''
          present:
            summary: 'When the value is present'
            value: 5
  /api/module/powerpoint/content-details:
    get:
      summary: 'Retrieve Detailed Powerpoint Module Info'
      operationId: retrieveDetailedPowerpointModuleInfo
      description: "Retrieves details of a Powerpoint module for the current user. Returns related fields\nsuch as module name, slug, viewer type, URL, content, and time spent on the module."
      parameters:
        -
          in: query
          name: moduleId
          description: 'The ID of the Powerpoint module.'
          example: '9'
          required: true
          schema:
            type: string
            description: 'The ID of the Powerpoint module.'
            example: '9'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Module Name'
                  slug: module-slug
                  viewer: google_viewer
                  url: '//docs.google.com/viewer?url=...'
                  content: 'Module content here...'
                  timeSpent: 120
                properties:
                  name:
                    type: string
                    example: 'Module Name'
                  slug:
                    type: string
                    example: module-slug
                  viewer:
                    type: string
                    example: google_viewer
                  url:
                    type: string
                    example: '//docs.google.com/viewer?url=...'
                  content:
                    type: string
                    example: 'Module content here...'
                  timeSpent:
                    type: integer
                    example: 120
      tags:
        - Powerpoint
      security: []
  /api/questions/tabularlist:
    get:
      summary: 'Questions Tabular List'
      operationId: questionsTabularList
      description: "Returns all the questions in a tabular list format in paginated mode.\nYou can apply filter using search_param via questionTypes, questionCategoryIds, quizModuleId and questionName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName": "name", "direction": "asc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName": "name", "direction": "asc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"questionTypes":[],"questionCategoryIds":[],"quizModuleId":"","questionName":""}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"questionTypes":[],"questionCategoryIds":[],"quizModuleId":"","questionName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      title: Question-1
                      type: multiple_choice
                      display_type: 'Multiple Choice'
                      categories: Category-1
                      author: 'John Doe'
                      created_at: '2021-01-01 12:00:00'
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        title: Question-1
                        type: multiple_choice
                        display_type: 'Multiple Choice'
                        categories: Category-1
                        author: 'John Doe'
                        created_at: '2021-01-01 12:00:00'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: Question-1
                        type:
                          type: string
                          example: multiple_choice
                        display_type:
                          type: string
                          example: 'Multiple Choice'
                        categories:
                          type: string
                          example: Category-1
                        author:
                          type: string
                          example: 'John Doe'
                        created_at:
                          type: string
                          example: '2021-01-01 12:00:00'
      tags:
        - Questions
      security: []
  /api/questions/type/lookup:
    get:
      summary: 'Lookup for question types.'
      operationId: lookupForQuestionTypes
      description: 'Returns an array of all available question types.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  db_value: multiple_choice
                  display_value: 'Multiple Choice'
                properties:
                  db_value:
                    type: string
                    example: multiple_choice
                  display_value:
                    type: string
                    example: 'Multiple Choice'
      tags:
        - Questions
      security: []
  /api/question/lookup:
    get:
      summary: 'Lookup for questions.'
      operationId: lookupForQuestions
      description: "Searches for questions based on a search term provided in the request.\nReturns a list of questions with their IDs and titles that match the search term.\nThe response is formatted to include 'value' as the question ID and 'label'\nas the question title for each matching question."
      parameters:
        -
          in: query
          name: search_term
          description: 'The term to search for in question titles.'
          example: nobis
          required: true
          schema:
            type: string
            description: 'The term to search for in question titles.'
            example: nobis
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    value: 1
                    label: 'Question Title 1'
                  -
                    value: 2
                    label: 'Question Title 2'
      tags:
        - Questions
      security: []
  /api/questions/quickEdit:
    post:
      summary: 'Quick Edit'
      operationId: quickEdit
      description: 'Updates the details in bulk for a specified question. Parameters is provided which needs to be updated. (See Parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Questions updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Questions updated Successfully'
      tags:
        - Questions
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                question_ids:
                  type: array
                  description: 'All question IDs which needs to be updated.'
                  example:
                    - 3
                    - 2
                  items:
                    type: string
                author_id:
                  type: integer
                  description: 'Update the instructor/Author for the selected questions.'
                  example: 1
                categories_id:
                  type: array
                  description: 'Update the categories of selected questions.'
                  example:
                    - 6
                  items:
                    type: string
              required:
                - question_ids
      security: []
  /api/questions:
    post:
      summary: 'Creates a new question with the given details.'
      operationId: createsANewQuestionWithTheGivenDetails
      description: 'Validates the question details and stores the question in the database.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 4
                  message: 'Question saved successfully'
                properties:
                  id:
                    type: integer
                    example: 4
                  message:
                    type: string
                    example: 'Question saved successfully'
      tags:
        - Questions
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                title:
                  type: string
                  description: 'Title of the question.'
                  example: Q1
                content:
                  type: string
                  description: 'Content for the text modules that students will see.'
                  example: '<p>This is the short content here</p>'
                type:
                  type: string
                  description: 'Type of the question. Type options: multiple_choice, multiple_correct or short_answers.'
                  example: multiple_choice
                hint:
                  type: string
                  description: 'Hint for the question for students.'
                  example: 'SpaceX owner'
                explanation:
                  type: string
                  description: 'Explanation of the answer for students.'
                  example: 'Elon owns Tesla car company'
                categories:
                  type: array
                  description: 'Categories for the question.'
                  example:
                    - 12
                    - 16
                  items:
                    type: string
                options:
                  type: array
                  description: 'Options and correct answer for this question.'
                  example:
                    - soluta
                  items:
                    type: string
                matchPossibilities:
                  type: string
                  description: 'Match possibilities for the question.'
                  example: '{ "item": "Apple", "match": "Fruit" }'
              required:
                - title
                - type
      security: []
  '/api/question/{id}':
    get:
      summary: 'Retrieves the details of a specified question. Helps in fetching question using its ID. (See Parameters)'
      operationId: retrievesTheDetailsOfASpecifiedQuestionHelpsInFetchingQuestionUsingItsIDSeeParameters
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 4
                  title: Q1
                  content: '<p>This is the short content here</p>'
                  hint: 'SpaceX owner'
                  explanation: 'Elon owns Tesla car company'
                  type: multiple_choice
                  categories:
                    - 12
                    - 16
                  options:
                    -
                      value: 'Elon Musk'
                      is_correct: true
                    -
                      value: 'Jeff bezos'
                      is_correct: false
                properties:
                  id:
                    type: integer
                    example: 4
                  title:
                    type: string
                    example: Q1
                  content:
                    type: string
                    example: '<p>This is the short content here</p>'
                  hint:
                    type: string
                    example: 'SpaceX owner'
                  explanation:
                    type: string
                    example: 'Elon owns Tesla car company'
                  type:
                    type: string
                    example: multiple_choice
                  categories:
                    type: array
                    example:
                      - 12
                      - 16
                    items:
                      type: integer
                  options:
                    type: array
                    example:
                      -
                        value: 'Elon Musk'
                        is_correct: true
                      -
                        value: 'Jeff bezos'
                        is_correct: false
                    items:
                      type: object
                      properties:
                        value:
                          type: string
                          example: 'Elon Musk'
                        is_correct:
                          type: boolean
                          example: true
      tags:
        - Questions
      security: []
    put:
      summary: 'Update Question'
      operationId: updateQuestion
      description: "Updates the details of a specified question. (See parameters)\nQuestions can be used in the quizzes as quiz's content."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Question updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Question updated successfully'
      tags:
        - Questions
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'ID of the question you want to edit.'
                  example: '7'
                title:
                  type: required
                  description: 'Title of the question.'
                  example: Q1
                content:
                  type: string
                  description: 'Content for the text modules that students will see.'
                  example: '<p>This is the short content here<\/p>'
                type:
                  type: required
                  description: 'Type of the question. Type options: multiple_choice, multiple_correct or short_answers.'
                  example: multiple_choice
                hint:
                  type: string
                  description: 'Hint for the question for students.'
                  example: 'Hint here'
                explanation:
                  type: string
                  description: 'Explanation of the answer for students.'
                  example: 'This is the explanation'
                options:
                  type: required
                  description: 'Array of options and correct answer for this question.'
                  example: '[{value: \"Elon Musk\", is_correct: true}, {value: \"Jeff bezos\", is_correct: false}]'
                categories:
                  type: array
                  description: 'Categories of the question.'
                  example:
                    - 3
                    - 4
                  items:
                    type: string
                matchPossibilities:
                  type: string
                  description: 'if type is match_answers.'
                  example: 'Possibility 1, Possibility 2'
              required:
                - matchPossibilities
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the question you want to fetch the details of.'
        example: 2
        required: true
        schema:
          type: integer
  /api/question/delete:
    post:
      summary: 'Delete question'
      operationId: deleteQuestion
      description: "To delete a question, you need to use this request.\nReturns number of question deleted(if multiple selected) and also not deleted. (See Response)"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '3 question(s) deleted 2 question(s) not deleted as it is used in quiz. Please remove the question(s) from the quiz and try again.'
                  deletedQuestions:
                    - 1
                    - 2
                    - 3
                  notDeletedQuestions:
                    - 5
                    - 6
                  usedInPlaces:
                    'Question Category-1':
                      -
                        id: 1
                        name: Quiz-1
                    'Question Category-2':
                      -
                        id: 2
                        name: Quiz-2
                properties:
                  message:
                    type: string
                    example: '3 question(s) deleted 2 question(s) not deleted as it is used in quiz. Please remove the question(s) from the quiz and try again.'
                  deletedQuestions:
                    type: array
                    example:
                      - 1
                      - 2
                      - 3
                    items:
                      type: integer
                  notDeletedQuestions:
                    type: array
                    example:
                      - 5
                      - 6
                    items:
                      type: integer
                  usedInPlaces:
                    type: object
                    properties:
                      'Question Category-1':
                        type: array
                        example:
                          -
                            id: 1
                            name: Quiz-1
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 1
                            name:
                              type: string
                              example: Quiz-1
                      'Question Category-2':
                        type: array
                        example:
                          -
                            id: 2
                            name: Quiz-2
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              example: 2
                            name:
                              type: string
                              example: Quiz-2
      tags:
        - Questions
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                delete_ids:
                  type: array
                  description: 'All question IDs which needs to be deleted.'
                  example:
                    - 1
                    - 12
                    - 15
                  items:
                    type: string
              required:
                - delete_ids
      security: []
  /api/question/bulkUpload:
    post:
      summary: 'Bulk upload questions from CSV file'
      operationId: bulkUploadQuestionsFromCSVFile
      description: ''
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Question(s) uploaded successfully'
                  status: success
                  title: Success
                  errors:
                    -
                      - 'Row #1 : Question Type is not correct.'
                      - 'Row #2 : Empty Title/Title too large(It must be under 500 characters).'
                      - 'Row #2 : Multiple Choice - Incorrect value in Correct_Answer column. Correct_Answer column must contain only Numbers(>0)'
                  successfulRow: 4
                  skipped: 2
                  insertedQuestions:
                    -
                      id: 1
                      title: Question1
                    -
                      id: 2
                      title: Question2
                    -
                      id: 3
                      title: Question3
                    -
                      id: 4
                      title: Question4
                properties:
                  message:
                    type: string
                    example: 'Question(s) uploaded successfully'
                  status:
                    type: string
                    example: success
                  title:
                    type: string
                    example: Success
                  errors:
                    type: array
                    example:
                      -
                        - 'Row #1 : Question Type is not correct.'
                        - 'Row #2 : Empty Title/Title too large(It must be under 500 characters).'
                        - 'Row #2 : Multiple Choice - Incorrect value in Correct_Answer column. Correct_Answer column must contain only Numbers(>0)'
                    items:
                      type: array
                  successfulRow:
                    type: integer
                    example: 4
                  skipped:
                    type: integer
                    example: 2
                  insertedQuestions:
                    type: array
                    example:
                      -
                        id: 1
                        title: Question1
                      -
                        id: 2
                        title: Question2
                      -
                        id: 3
                        title: Question3
                      -
                        id: 4
                        title: Question4
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: Question1
      tags:
        - Questions
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                questionList:
                  type: array
                  description: 'Question List. See the example request.'
                  example:
                    - deserunt
                  items:
                    type: string
                quizIds:
                  type: array
                  description: 'Quiz Ids to which the questions should be added'
                  example:
                    - at
                  items:
                    type: string
                quiztype:
                  type: string
                  description: 'Type of quiz, new or existing'
                  example: non
                newQuiz:
                  type: string
                  description: 'Name of the new quiz'
                  example: labore
              required:
                - questionList
                - quizIds
                - quiztype
                - newQuiz
      security: []
  /api/quickbooks/logs:
    get:
      summary: 'Returns all the QuickBooks logs in a tabular list format in paginated mode.'
      operationId: returnsAllTheQuickBooksLogsInATabularListFormatInPaginatedMode
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'For filtering records based on the columns provided in JSON format.'
          example: '{"entity": "order", "entityId": 10, "status": "success"}'
          required: false
          schema:
            type: string
            description: 'For filtering records based on the columns provided in JSON format.'
            example: '{"entity": "order", "entityId": 10, "status": "success"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      event: new_account_created
                      data: []
                      status: success
                      errorMessage: ''
                      created_at: 'Aug 03, 2020 09:56 AM'
                      showData: false
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        event: new_account_created
                        data: []
                        status: success
                        errorMessage: ''
                        created_at: 'Aug 03, 2020 09:56 AM'
                        showData: false
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        event:
                          type: string
                          example: new_account_created
                        data:
                          type: array
                          example: []
                        status:
                          type: string
                          example: success
                        errorMessage:
                          type: string
                          example: ''
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        showData:
                          type: boolean
                          example: false
      tags:
        - 'QuickBooks Integration'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the QuickBooks action.'
        example: '50'
        required: true
        schema:
          type: string
  /api/modules/quiz:
    get:
      summary: 'Quizzes Tabular List'
      operationId: quizzesTabularList
      description: "Returns all the quizzes in a tabular list format with pagination.\nFilters can be applied using search parameters for associated courses and module names."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of items per page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of items per page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number for pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number for pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'Optional JSON for sorting items by column.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'Optional JSON for sorting items by column.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'Optional JSON for searching by associatedCourse and moduleName.'
          example: '{"associatedCourse": "", "moduleName": ""}'
          required: false
          schema:
            type: string
            description: 'Optional JSON for searching by associatedCourse and moduleName.'
            example: '{"associatedCourse": "", "moduleName": ""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 5
                  records:
                    -
                      id: 1
                      name: 'Quiz 1'
                      slug: quiz-1
                      type: quiz
                      totalQuestions: 5
                      icon: '<i class="el-icon-tickets"></i>'
                      author: 'John Doe'
                      showMappedCourses: false
                      created_at: 'Aug 03, 2020 09:56 AM'
                      course_count: 2
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 5
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Quiz 1'
                        slug: quiz-1
                        type: quiz
                        totalQuestions: 5
                        icon: '<i class="el-icon-tickets"></i>'
                        author: 'John Doe'
                        showMappedCourses: false
                        created_at: 'Aug 03, 2020 09:56 AM'
                        course_count: 2
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Quiz 1'
                        slug:
                          type: string
                          example: quiz-1
                        type:
                          type: string
                          example: quiz
                        totalQuestions:
                          type: integer
                          example: 5
                        icon:
                          type: string
                          example: '<i class="el-icon-tickets"></i>'
                        author:
                          type: string
                          example: 'John Doe'
                        showMappedCourses:
                          type: boolean
                          example: false
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        course_count:
                          type: integer
                          example: 2
      tags:
        - Quizzes
      security: []
    post:
      summary: 'Creates a new Quiz Module.'
      operationId: createsANewQuizModule
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - Quizzes
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: required
                  description: 'The name of the quiz module.'
                  example: nam
                content:
                  type: string
                  description: 'The content of the quiz module.'
                  example: aut
                type:
                  type: required
                  description: 'The type of the quiz, either static or dynamic.'
                  example: eius
                showCorrectAnswerOption:
                  type: required
                  description: 'Whether to show correct answer. Options: always, never, not_till_retake_allowed.'
                  example: dolorum
                shuffleQuestions:
                  type: boolean
                  description: 'Whether to shuffle the questions.'
                  example: false
                forceSequential:
                  type: boolean
                  description: 'Whether to force the questions sequential.'
                  example: false
                realTimeGrading:
                  type: boolean
                  description: 'Whether to grade the quiz in real time.'
                  example: true
                noOfRetakesAllowed:
                  type: integer
                  description: 'The number of retakes allowed. 0 means unlimited.'
                  example: 7
                minimumPassingMarks:
                  type: integer
                  description: 'The minimum passing marks.'
                  example: 18
                questions:
                  type: 'required_if:type,static'
                  description: 'The questions to be included in the quiz.'
                  example: vero
                questionCategories:
                  type: 'required_if:type,dynamic'
                  description: 'The categories of questions to be included in the quiz.'
                  example: praesentium
                maxSpentHour:
                  type: integer
                  description: 'The maximum time to be spent in hours.'
                  example: 5
                maxSpentMinutes:
                  type: integer
                  description: 'The maximum time to be spent in minutes.'
                  example: 8
                estimatedCompletion:
                  type: string
                  description: 'The estimated time to complete the quiz.'
                  example: autem
                estimationCompletedUnit:
                  type: string
                  description: 'The unit of estimated time to complete the quiz.'
                  example: qui
      security: []
  '/api/modules/quiz/{id}':
    get:
      summary: 'Get Quiz Module'
      operationId: getQuizModule
      description: 'Returns the details of the specified quiz module.'
      parameters:
        -
          in: query
          name: id
          description: 'ID of the quiz module.'
          example: '6'
          required: true
          schema:
            type: string
            description: 'ID of the quiz module.'
            example: '6'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 8
                  name: Quiz-2
                  slug: quiz-2
                  content: '<p>afegrshtdh</p>'
                  type: static
                  shuffleQuestions: true
                  forceSequential: true
                  realTimeGrading: true
                  showCorrectAnswerOption: always
                  noOfRetakesAllowed: 3
                  minimumPassingMarks: null
                  questions:
                    -
                      id: 3
                      title: 'Is red a color?'
                  questionCategories: []
                  maxSpentMinutes: ''
                  maxSpentHour: ''
                properties:
                  id:
                    type: integer
                    example: 8
                  name:
                    type: string
                    example: Quiz-2
                  slug:
                    type: string
                    example: quiz-2
                  content:
                    type: string
                    example: '<p>afegrshtdh</p>'
                  type:
                    type: string
                    example: static
                  shuffleQuestions:
                    type: boolean
                    example: true
                  forceSequential:
                    type: boolean
                    example: true
                  realTimeGrading:
                    type: boolean
                    example: true
                  showCorrectAnswerOption:
                    type: string
                    example: always
                  noOfRetakesAllowed:
                    type: integer
                    example: 3
                  minimumPassingMarks:
                    type: string
                    example: null
                  questions:
                    type: array
                    example:
                      -
                        id: 3
                        title: 'Is red a color?'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 3
                        title:
                          type: string
                          example: 'Is red a color?'
                  questionCategories:
                    type: array
                    example: []
                  maxSpentMinutes:
                    type: string
                    example: ''
                  maxSpentHour:
                    type: string
                    example: ''
      tags:
        - Quizzes
      security: []
    put:
      summary: 'Update Quiz Module'
      operationId: updateQuizModule
      description: "Updates the details of a specified quiz module. This includes both static and dynamic types.\nValidates and processes the module details, including questions or question categories,\nand updates the associated database records accordingly."
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 5
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 5
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - Quizzes
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the quiz module.'
                  example: Quiz-1
                content:
                  type: string
                  description: 'Content for the quiz module.'
                  example: '<p>Quiz content</p>'
                type:
                  type: string
                  description: "Type of the quiz, either 'static' or 'dynamic'."
                  example: et
                showCorrectAnswerOption:
                  type: string
                  description: 'Option to show correct answers: always, never, or not_till_retake_allowed.'
                  example: qui
                shuffleQuestions:
                  type: boolean
                  description: 'Shuffle the questions in the quiz.'
                  example: true
                forceSequential:
                  type: boolean
                  description: 'Display questions in a fixed order.'
                  example: true
                realTimeGrading:
                  type: boolean
                  description: 'Enable real-time grading.'
                  example: false
                noOfRetakesAllowed:
                  type: integer
                  description: 'Maximum number of retakes allowed for the quiz. Maximum: 9999.'
                  example: 4
                minimumPassingMarks:
                  type: integer
                  description: 'Minimum percentage required to pass the quiz.'
                  example: 4
                questions:
                  type: array
                  description: 'required_if:type,static List of questions for static quizzes.'
                  example:
                    - voluptatem
                  items:
                    type: string
                questionCategories:
                  type: array
                  description: 'required_if:type,dynamic List of question categories for dynamic quizzes.'
                  example:
                    - dolorum
                  items:
                    type: string
                maxSpentHour:
                  type: integer
                  description: 'Maximum hours allowed for the quiz. Minimum: 0.'
                  example: 16
                maxSpentMinutes:
                  type: integer
                  description: 'Maximum minutes allowed for the quiz. Minimum: 0.'
                  example: 11
                estimatedCompletion:
                  type: string
                  description: 'Estimated time to complete the quiz.'
                  example: '00:30:00'
                estimationCompletedUnit:
                  type: string
                  description: 'Unit of estimated time to complete.'
                  example: minutes
              required:
                - name
                - type
                - showCorrectAnswerOption
      security: []
  /api/module/quiz/details:
    get:
      summary: 'Retrieves the details of the specified quiz module. Helps in fetching quiz module using module ID.'
      operationId: retrievesTheDetailsOfTheSpecifiedQuizModuleHelpsInFetchingQuizModuleUsingModuleID
      description: ''
      parameters:
        -
          in: query
          name: moduleId
          description: 'ID of the module.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the module.'
            example: '1'
        -
          in: query
          name: registrationId
          description: 'ID of the course registration.'
          example: '2'
          required: true
          schema:
            type: string
            description: 'ID of the course registration.'
            example: '2'
        -
          in: query
          name: portalId
          description: 'ID of the portal.'
          example: '3'
          required: true
          schema:
            type: string
            description: 'ID of the portal.'
            example: '3'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: Quiz-2
                  slug: quiz-2
                  content: '<p>afegrshtdh</p>'
                  courseId: 6
                  courseName: 'Course 1'
                  courseSlug: /course/1/launch
                  type: static
                  shuffleQuestion: true
                  forceSequential: true
                  realTimeGrading: true
                  showCorrectAnswerOption: always
                  minimumPassingMarks: null
                  maxTimer: ''
                  maxRetakesAllowed: 0
                  min_time_spent: 0
                  questions: []
                  otherModules: []
                  launchCheck:
                    canbeLaunched: true
                    reason: ''
                  userId: 1
                  showInstructionButton: true
                  prevSlug: ''
                  nextSlug: ''
                properties:
                  name:
                    type: string
                    example: Quiz-2
                  slug:
                    type: string
                    example: quiz-2
                  content:
                    type: string
                    example: '<p>afegrshtdh</p>'
                  courseId:
                    type: integer
                    example: 6
                  courseName:
                    type: string
                    example: 'Course 1'
                  courseSlug:
                    type: string
                    example: /course/1/launch
                  type:
                    type: string
                    example: static
                  shuffleQuestion:
                    type: boolean
                    example: true
                  forceSequential:
                    type: boolean
                    example: true
                  realTimeGrading:
                    type: boolean
                    example: true
                  showCorrectAnswerOption:
                    type: string
                    example: always
                  minimumPassingMarks:
                    type: string
                    example: null
                  maxTimer:
                    type: string
                    example: ''
                  maxRetakesAllowed:
                    type: integer
                    example: 0
                  min_time_spent:
                    type: integer
                    example: 0
                  questions:
                    type: array
                    example: []
                  otherModules:
                    type: array
                    example: []
                  launchCheck:
                    type: object
                    properties:
                      canbeLaunched:
                        type: boolean
                        example: true
                      reason:
                        type: string
                        example: ''
                  userId:
                    type: integer
                    example: 1
                  showInstructionButton:
                    type: boolean
                    example: true
                  prevSlug:
                    type: string
                    example: ''
                  nextSlug:
                    type: string
                    example: ''
      tags:
        - Quizzes
      security: []
  '/api/modules/quiz/{id}/saveAnswer':
    put:
      summary: 'Save the answer of the question in the quiz module'
      operationId: saveTheAnswerOfTheQuestionInTheQuizModule
      description: "Saves the answer of the question in the quiz module. Updates the status of quiz to completed if student is finished the quiz and submits.\n(See Parameters)"
      parameters:
        -
          in: query
          name: questionId
          description: 'ID of the question is user is answering.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the question is user is answering.'
            example: '1'
        -
          in: query
          name: moduleStatusId
          description: 'ID of the Module status of the current quiz.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'ID of the Module status of the current quiz.'
            example: '10'
        -
          in: query
          name: isAnswerSubmitted
          description: 'boolean to check if answer is submitted or not.'
          example: 'true'
          required: true
          schema:
            type: string
            description: 'boolean to check if answer is submitted or not.'
            example: 'true'
        -
          in: query
          name: markedAnswer
          description: 'Answer marked by the user.'
          example: A
          required: true
          schema:
            type: string
            description: 'Answer marked by the user.'
            example: A
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Answer saved successfully'
                  isCorrect: true
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Answer saved successfully'
                  isCorrect:
                    type: boolean
                    example: true
      tags:
        - Quizzes
      security: []
  '/api/modules/quiz/{id}/submitQuiz':
    put:
      summary: 'Submits the quiz after attempting all the questions of the quiz. Updates the status of quiz to completed if student is finished the quiz and submits.'
      operationId: submitsTheQuizAfterAttemptingAllTheQuestionsOfTheQuizUpdatesTheStatusOfQuizToCompletedIfStudentIsFinishedTheQuizAndSubmits
      description: ''
      parameters:
        -
          in: query
          name: portalId
          description: 'The ID of the portal for the user.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of the portal for the user.'
            example: '1'
        -
          in: query
          name: questions
          description: 'An array of questions in the current quiz.'
          example: '[{"id":1,"type":"multiple_choice","markedAnswer":"A"}]'
          required: true
          schema:
            type: string
            description: 'An array of questions in the current quiz.'
            example: '[{"id":1,"type":"multiple_choice","markedAnswer":"A"}]'
        -
          in: query
          name: statusRowId
          description: 'The ID of the module status for the current quiz.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The ID of the module status for the current quiz.'
            example: '10'
        -
          in: query
          name: retakeCounter
          description: 'The number of times the quiz has been retaken.'
          example: '2'
          required: true
          schema:
            type: string
            description: 'The number of times the quiz has been retaken.'
            example: '2'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Quiz Submitted Successfully'
                  course_newly_completed: false
                properties:
                  message:
                    type: string
                    example: 'Quiz Submitted Successfully'
                  course_newly_completed:
                    type: boolean
                    example: false
      tags:
        - Quizzes
      security: []
  /api/module/quiz/results:
    get:
      summary: 'Get Quiz Module Results'
      operationId: getQuizModuleResults
      description: 'Retrieves the quiz module results based on the status row ID specified.'
      parameters:
        -
          in: query
          name: statusRowId
          description: 'The ID of the status row.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The ID of the status row.'
            example: '10'
        -
          in: query
          name: studentId
          description: 'The ID of the student.'
          example: '2'
          required: true
          schema:
            type: string
            description: 'The ID of the student.'
            example: '2'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Quiz 1'
                  slug: quiz-1
                  status: Completed
                  questions:
                    -
                      id: 1
                      title: 'Question 1'
                      type: 'Multiple Choice'
                      content: 'What is your question?'
                      explanation: 'This is the explanation'
                      is_correct: true
                      marked_answer: A
                      correct_answer: A
                      created_at: '2020-03-03 10:30:00'
                  studentName: 'John Doe'
                  totalQuestions: 5
                  totalCorrect: 4
                  totalInCorrect: 1
                  minimumPassingAchieved: true
                  score: 80
                  percentAchieved: 80.0
                  showCorrectAnswerOption: true
                  courseCompleted: false
                  totalRetakeallowed: 3
                  attemptCount: 2
                  timeSpent: '00:30:00'
                  minimumPassingMarks: 90
                  isRetakeAllowed: true
                properties:
                  name:
                    type: string
                    example: 'Quiz 1'
                  slug:
                    type: string
                    example: quiz-1
                  status:
                    type: string
                    example: Completed
                  questions:
                    type: array
                    example:
                      -
                        id: 1
                        title: 'Question 1'
                        type: 'Multiple Choice'
                        content: 'What is your question?'
                        explanation: 'This is the explanation'
                        is_correct: true
                        marked_answer: A
                        correct_answer: A
                        created_at: '2020-03-03 10:30:00'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: 'Question 1'
                        type:
                          type: string
                          example: 'Multiple Choice'
                        content:
                          type: string
                          example: 'What is your question?'
                        explanation:
                          type: string
                          example: 'This is the explanation'
                        is_correct:
                          type: boolean
                          example: true
                        marked_answer:
                          type: string
                          example: A
                        correct_answer:
                          type: string
                          example: A
                        created_at:
                          type: string
                          example: '2020-03-03 10:30:00'
                  studentName:
                    type: string
                    example: 'John Doe'
                  totalQuestions:
                    type: integer
                    example: 5
                  totalCorrect:
                    type: integer
                    example: 4
                  totalInCorrect:
                    type: integer
                    example: 1
                  minimumPassingAchieved:
                    type: boolean
                    example: true
                  score:
                    type: integer
                    example: 80
                  percentAchieved:
                    type: number
                    example: 80.0
                  showCorrectAnswerOption:
                    type: boolean
                    example: true
                  courseCompleted:
                    type: boolean
                    example: false
                  totalRetakeallowed:
                    type: integer
                    example: 3
                  attemptCount:
                    type: integer
                    example: 2
                  timeSpent:
                    type: string
                    example: '00:30:00'
                  minimumPassingMarks:
                    type: integer
                    example: 90
                  isRetakeAllowed:
                    type: boolean
                    example: true
      tags:
        - Quizzes
      security: []
  /api/quiz/dropdownlist:
    get:
      summary: 'Quiz Lookup'
      operationId: quizLookup
      description: "Retrieves all the quiz modules. Helps while showing quiz names in form elements like dropdown.\nYou can apply filters using search_term parameter. (See Response)"
      parameters:
        -
          in: query
          name: search_term
          description: 'The name or substring of the quiz name to search for that module.'
          example: molestiae
          required: true
          schema:
            type: string
            description: 'The name or substring of the quiz name to search for that module.'
            example: molestiae
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    value: 1
                    label: First-quiz
                  -
                    value: 2
                    label: Quiz-2
      tags:
        - Quizzes
      security: []
  /api/quiz/quizAnalysis:
    get:
      summary: 'Returns the analysis details of a quiz, including the questions, options selected, percentages etc.'
      operationId: returnsTheAnalysisDetailsOfAQuizIncludingTheQuestionsOptionsSelectedPercentagesEtc
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  quizName: 'Quiz Example'
                  totalSubmissions: 5
                  questionDetails:
                    -
                      id: 1
                      name: 'What is your name?'
                      questionType: 'Multiple Choice'
                      correctOption:
                        - 1
                        - 2
                      optionsWithPercentage:
                        'Option A': 20
                        'Option B': 40
                        'Option C': 40
                    -
                      id: 2
                      name: 'What is your age?'
                      questionType: 'Short Answer'
                      correctOption: []
                      optionsWithPercentage:
                        18-24: 60
                        25-34: 20
                        35-44: 20
                  totalQuestions: 5
                  recordsFiltered: 5
                  quizStatistics:
                    averageScore: 80
                    averageTimeSpent: '00:30:00'
                    totalSubmissions: 5
                  averageTimeSpent: '00:30:00'
                  totalAttempts: 10
                  headers:
                    - optionName_1
                    - markedPercentageOfOption_1
                    - optionName_2
                    - markedPercentageOfOption_2
                    - optionName_3
                    - markedPercentageOfOption_3
                properties:
                  quizName:
                    type: string
                    example: 'Quiz Example'
                  totalSubmissions:
                    type: integer
                    example: 5
                  questionDetails:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'What is your name?'
                        questionType: 'Multiple Choice'
                        correctOption:
                          - 1
                          - 2
                        optionsWithPercentage:
                          'Option A': 20
                          'Option B': 40
                          'Option C': 40
                      -
                        id: 2
                        name: 'What is your age?'
                        questionType: 'Short Answer'
                        correctOption: []
                        optionsWithPercentage:
                          18-24: 60
                          25-34: 20
                          35-44: 20
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'What is your name?'
                        questionType:
                          type: string
                          example: 'Multiple Choice'
                        correctOption:
                          type: array
                          example:
                            - 1
                            - 2
                          items:
                            type: integer
                        optionsWithPercentage:
                          type: object
                          properties:
                            'Option A':
                              type: integer
                              example: 20
                            'Option B':
                              type: integer
                              example: 40
                            'Option C':
                              type: integer
                              example: 40
                  totalQuestions:
                    type: integer
                    example: 5
                  recordsFiltered:
                    type: integer
                    example: 5
                  quizStatistics:
                    type: object
                    properties:
                      averageScore:
                        type: integer
                        example: 80
                      averageTimeSpent:
                        type: string
                        example: '00:30:00'
                      totalSubmissions:
                        type: integer
                        example: 5
                  averageTimeSpent:
                    type: string
                    example: '00:30:00'
                  totalAttempts:
                    type: integer
                    example: 10
                  headers:
                    type: array
                    example:
                      - optionName_1
                      - markedPercentageOfOption_1
                      - optionName_2
                      - markedPercentageOfOption_2
                      - optionName_3
                      - markedPercentageOfOption_3
                    items:
                      type: string
      tags:
        - Quizzes
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                page_size:
                  type: integer
                  description: 'The number of records to return per page.'
                  example: 17
                page_number:
                  type: integer
                  description: 'The page number to return.'
                  example: 14
                search_param:
                  type: string
                  description: 'The search query to filter the results by.'
                  example: aspernatur
                quiz_id:
                  type: integer
                  description: 'The id of the quiz module.'
                  example: 10
              required:
                - page_size
                - page_number
                - quiz_id
      security: []
  /api/quiz/getQuestionSubmissionDetails:
    get:
      summary: 'Get the question submission details'
      operationId: getTheQuestionSubmissionDetails
      description: 'Retrieves the question submission details based on the question ID and quiz ID specified.'
      parameters:
        -
          in: query
          name: quiz_id
          description: 'The ID of the quiz.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of the quiz.'
            example: '1'
        -
          in: query
          name: question_id
          description: 'The ID of the question.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of the question.'
            example: '1'
        -
          in: query
          name: page_size
          description: 'The number of records to be returned in a single page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of records to be returned in a single page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'The page number to be returned.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The page number to be returned.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  totalRecords: 100
                  records:
                    -
                      courseName: 'Course 1'
                      firstName: John
                      lastName: Doe
                      email: john@example.com
                      questionType: 'Multiple Choice'
                      markedAnswer: A
                      isCorrectResponse: 'Yes'
                properties:
                  totalRecords:
                    type: integer
                    example: 100
                  records:
                    type: array
                    example:
                      -
                        courseName: 'Course 1'
                        firstName: John
                        lastName: Doe
                        email: john@example.com
                        questionType: 'Multiple Choice'
                        markedAnswer: A
                        isCorrectResponse: 'Yes'
                    items:
                      type: object
                      properties:
                        courseName:
                          type: string
                          example: 'Course 1'
                        firstName:
                          type: string
                          example: John
                        lastName:
                          type: string
                          example: Doe
                        email:
                          type: string
                          example: john@example.com
                        questionType:
                          type: string
                          example: 'Multiple Choice'
                        markedAnswer:
                          type: string
                          example: A
                        isCorrectResponse:
                          type: string
                          example: 'Yes'
      tags:
        - Quizzes
      security: []
  '/api/quiz/pdf/{id}':
    get:
      summary: 'Downloads the quiz response as a PDF.'
      operationId: downloadsTheQuizResponseAsAPDF
      description: "Generates a PDF file containing the details of the quiz response,\nincluding the name, retake information, time spent, questions,\nanswers, and scores. The PDF is then returned as a downloadable file."
      parameters:
        -
          in: query
          name: statusRowId
          description: 'The ID of the status row.'
          example: consequuntur
          required: true
          schema:
            type: string
            description: 'The ID of the status row.'
            example: consequuntur
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: 'PDF file containing the quiz response details.'
      tags:
        - Quizzes
      security: []
  /api/quiz/sendScore:
    post:
      summary: 'Send the quiz score achieved by the user to the LTI consumer.'
      operationId: sendTheQuizScoreAchievedByTheUserToTheLTIConsumer
      description: ''
      parameters:
        -
          in: query
          name: statusRowId
          description: 'The ID of the status row.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The ID of the status row.'
            example: '10'
        -
          in: query
          name: userId
          description: 'The ID of the user.'
          example: '2'
          required: true
          schema:
            type: string
            description: 'The ID of the user.'
            example: '2'
        -
          in: query
          name: ltiRegistrationId
          description: 'The ID of the LTI registration.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of the LTI registration.'
            example: '1'
        -
          in: query
          name: courseId
          description: 'The ID of the course.'
          example: '3'
          required: true
          schema:
            type: string
            description: 'The ID of the course.'
            example: '3'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: success
                  message: 'Score submitted successfully.'
                properties:
                  status:
                    type: string
                    example: success
                  message:
                    type: string
                    example: 'Score submitted successfully.'
        500:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: error
                  message: 'Error occured while submitting the score in a LTI. ModuleStatusId #<statusRowId> Error = <error message>'
                properties:
                  status:
                    type: string
                    example: error
                  message:
                    type: string
                    example: 'Error occured while submitting the score in a LTI. ModuleStatusId #<statusRowId> Error = <error message>'
      tags:
        - Quizzes
      security: []
  /api/module/quiz/content-details:
    get:
      summary: 'Get the quiz module content details'
      operationId: getTheQuizModuleContentDetails
      description: 'Retrieves the quiz module content details based on the quiz ID specified.'
      parameters:
        -
          in: query
          name: id
          description: 'The ID of the quiz.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The ID of the quiz.'
            example: '1'
        -
          in: query
          name: name
          description: 'The name of the quiz.'
          example: 'Quiz 1'
          required: true
          schema:
            type: string
            description: 'The name of the quiz.'
            example: 'Quiz 1'
        -
          in: query
          name: content
          description: 'The content of the quiz.'
          example: 'Quiz 1 content'
          required: true
          schema:
            type: string
            description: 'The content of the quiz.'
            example: 'Quiz 1 content'
        -
          in: query
          name: type
          description: 'The type of the quiz.'
          example: static
          required: true
          schema:
            type: string
            description: 'The type of the quiz.'
            example: static
        -
          in: query
          name: shuffleQuestions
          description: 'optional Whether to shuffle the questions or not.'
          example: 'true'
          required: false
          schema:
            type: string
            description: 'optional Whether to shuffle the questions or not.'
            example: 'true'
        -
          in: query
          name: forceSequential
          description: 'optional Whether to force sequential questions or not.'
          example: 'true'
          required: false
          schema:
            type: string
            description: 'optional Whether to force sequential questions or not.'
            example: 'true'
        -
          in: query
          name: realTimeGrading
          description: 'optional Whether to enable real time grading or not.'
          example: 'true'
          required: false
          schema:
            type: string
            description: 'optional Whether to enable real time grading or not.'
            example: 'true'
        -
          in: query
          name: slug
          description: 'The slug of the quiz.'
          example: quiz-1
          required: true
          schema:
            type: string
            description: 'The slug of the quiz.'
            example: quiz-1
        -
          in: query
          name: showCorrectAnswerOption
          description: 'The option to show correct answer.'
          example: always
          required: true
          schema:
            type: string
            description: 'The option to show correct answer.'
            example: always
        -
          in: query
          name: noOfRetakesAllowed
          description: 'The number of retakes allowed.'
          example: '2'
          required: true
          schema:
            type: string
            description: 'The number of retakes allowed.'
            example: '2'
        -
          in: query
          name: questionCategories
          description: 'The question categories.'
          example: '[{"categoryId": 1, "numOfQuestions": 2}]'
          required: true
          schema:
            type: string
            description: 'The question categories.'
            example: '[{"categoryId": 1, "numOfQuestions": 2}]'
        -
          in: query
          name: questions
          description: 'The questions.'
          example: '[{"id": 1, "title": "Question 1", "content": "Question 1 content", "type": "multiple_choice", "hint": "Hint 1", "explanation": "Explanation 1"}]'
          required: true
          schema:
            type: string
            description: 'The questions.'
            example: '[{"id": 1, "title": "Question 1", "content": "Question 1 content", "type": "multiple_choice", "hint": "Hint 1", "explanation": "Explanation 1"}]'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'Quiz 1'
                  content: 'Quiz 1 content'
                  type: static
                  shuffleQuestions: true
                  forceSequential: true
                  realTimeGrading: true
                  slug: quiz-1
                  showCorrectAnswerOption: always
                  noOfRetakesAllowed: 2
                  questionCategories:
                    -
                      categoryId: 1
                      numOfQuestions: 2
                  questions:
                    -
                      id: 1
                      title: 'Question 1'
                      content: 'Question 1 content'
                      type: multiple_choice
                      hint: 'Hint 1'
                      explanation: 'Explanation 1'
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'Quiz 1'
                  content:
                    type: string
                    example: 'Quiz 1 content'
                  type:
                    type: string
                    example: static
                  shuffleQuestions:
                    type: boolean
                    example: true
                  forceSequential:
                    type: boolean
                    example: true
                  realTimeGrading:
                    type: boolean
                    example: true
                  slug:
                    type: string
                    example: quiz-1
                  showCorrectAnswerOption:
                    type: string
                    example: always
                  noOfRetakesAllowed:
                    type: integer
                    example: 2
                  questionCategories:
                    type: array
                    example:
                      -
                        categoryId: 1
                        numOfQuestions: 2
                    items:
                      type: object
                      properties:
                        categoryId:
                          type: integer
                          example: 1
                        numOfQuestions:
                          type: integer
                          example: 2
                  questions:
                    type: array
                    example:
                      -
                        id: 1
                        title: 'Question 1'
                        content: 'Question 1 content'
                        type: multiple_choice
                        hint: 'Hint 1'
                        explanation: 'Explanation 1'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        title:
                          type: string
                          example: 'Question 1'
                        content:
                          type: string
                          example: 'Question 1 content'
                        type:
                          type: string
                          example: multiple_choice
                        hint:
                          type: string
                          example: 'Hint 1'
                        explanation:
                          type: string
                          example: 'Explanation 1'
      tags:
        - Quizzes
      security: []
  /api/scormpackages/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the SCORM packages in a tabular list format in paginated mode.\nYou can apply filter using search_param via name(package name), scormTypes(scorm type)."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName": "name", "direction": "asc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName": "name", "direction": "asc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"name": "my package", "scormTypes": ["SCORM 1.2", "xAPI"]}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"name": "my package", "scormTypes": ["SCORM 1.2", "xAPI"]}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      name: 'My Package'
                      url: 'https://example.com/scorm/1'
                      uploadId: 1
                      launchFile: launch.html
                      status: Completed
                      downloadStatus: Completed
                      downloadPath: 'https://example.com/scorm/1.zip'
                      full_url: 'https://example.com/scorm/1.zip'
                      version: 'SCORM 1.2'
                      author: 'John Doe'
                      created_at: '2021-01-01 12:00:00'
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'My Package'
                        url: 'https://example.com/scorm/1'
                        uploadId: 1
                        launchFile: launch.html
                        status: Completed
                        downloadStatus: Completed
                        downloadPath: 'https://example.com/scorm/1.zip'
                        full_url: 'https://example.com/scorm/1.zip'
                        version: 'SCORM 1.2'
                        author: 'John Doe'
                        created_at: '2021-01-01 12:00:00'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'My Package'
                        url:
                          type: string
                          example: 'https://example.com/scorm/1'
                        uploadId:
                          type: integer
                          example: 1
                        launchFile:
                          type: string
                          example: launch.html
                        status:
                          type: string
                          example: Completed
                        downloadStatus:
                          type: string
                          example: Completed
                        downloadPath:
                          type: string
                          example: 'https://example.com/scorm/1.zip'
                        full_url:
                          type: string
                          example: 'https://example.com/scorm/1.zip'
                        version:
                          type: string
                          example: 'SCORM 1.2'
                        author:
                          type: string
                          example: 'John Doe'
                        created_at:
                          type: string
                          example: '2021-01-01 12:00:00'
      tags:
        - 'SCORM Packages'
      security: []
  /api/scormpackages/scormTypeLookup:
    get:
      summary: 'Retrieve scorm type lookup'
      operationId: retrieveScormTypeLookup
      description: 'Returns all the supported scorm types in a list format.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "[\n    {'db_value' : 'SCORM 1.2', 'display_value' : 'Scorm version 1.2'},\n    {'db_value' : 'SCORM 2004', 'display_value' : 'Scorm version 2004'},\n    {'db_value' : 'xAPI', 'display_value' : 'xAPI'}\n]"
      tags:
        - 'SCORM Packages'
      security: []
  '/api/scormpackage/{id}':
    get:
      summary: 'Get Scorm Package'
      operationId: getScormPackage
      description: "Fetch the details of a specified scorm package. (See parameters)\nScorm packages can be used in course as course content/lesson."
      parameters:
        -
          in: query
          name: id
          description: 'ID of the scorm package you want to fetch the details of.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the scorm package you want to fetch the details of.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'New Scorm'
                  url: 'https://aomlms.com/scorm/sample-course/scormcontent/index.html'
                  version: '1.2'
                  launch_file: index_lms.html
                properties:
                  name:
                    type: string
                    example: 'New Scorm'
                  url:
                    type: string
                    example: 'https://aomlms.com/scorm/sample-course/scormcontent/index.html'
                  version:
                    type: string
                    example: '1.2'
                  launch_file:
                    type: string
                    example: index_lms.html
      tags:
        - 'SCORM Packages'
      security: []
  /api/scormpackage/delete:
    post:
      summary: 'Deletes a scorm package.'
      operationId: deletesAScormPackage
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: '1 package(s) deleted 0 package(s) not deleted as it is used in Module. Please remove the scorm Package from the module and try again.'
                properties:
                  message:
                    type: string
                    example: '1 package(s) deleted 0 package(s) not deleted as it is used in Module. Please remove the scorm Package from the module and try again.'
      tags:
        - 'SCORM Packages'
      security: []
    parameters:
      -
        in: path
        name: delete_ids
        description: 'IDs of the scorm package you want to delete.'
        example: maiores
        required: true
        schema:
          type: string
  /api/scormpackage/download:
    post:
      summary: 'Download a SCORM package'
      operationId: downloadASCORMPackage
      description: "This endpoint downloads a SCORM package by ID. After download, the status is reset to \"Not Started\"\nand the download path is cleared. The file is automatically deleted after being sent."
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: 'file binary The SCORM package ZIP file.'
      tags:
        - 'SCORM Packages'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The ID of the SCORM package to download.'
                  example: 5
              required:
                - id
      security: []
  /api/scormpackage/export:
    post:
      summary: 'Export Scorm Package'
      operationId: exportScormPackage
      description: 'Only admin, owner and staff can export the scorm package.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: 'In Progress'
                properties:
                  status:
                    type: string
                    example: 'In Progress'
      tags:
        - 'SCORM Packages'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the scorm package you want to export.'
        example: in
        required: true
        schema:
          type: string
  '/api/scormpackage/getDownloadStatus/{id}':
    get:
      summary: 'Returns the status of a scorm package.'
      operationId: returnsTheStatusOfAScormPackage
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: 'Not Started'
                properties:
                  status:
                    type: string
                    example: 'Not Started'
      tags:
        - 'SCORM Packages'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the scorm package.'
        example: aperiam
        required: true
        schema:
          type: string
  /api/aom-tincan-fake/v1/activities/state:
    get:
      summary: 'Get fake Tin Can state'
      operationId: getFakeTinCanState
      description: 'Returns a JSON response of true.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  success: true
                properties:
                  success:
                    type: boolean
                    example: true
      tags:
        - 'SCORMs '
      security: []
    put:
      summary: 'Get fake Tin Can state'
      operationId: getFakeTinCanState
      description: 'Returns a JSON response of true.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  success: true
                properties:
                  success:
                    type: boolean
                    example: true
      tags:
        - 'SCORMs '
      security: []
    parameters:
      -
        in: path
        name: modulesStatusId
        description: 'ID of the module status you want to update the Tin Can state of.'
        example: 3
        required: true
        schema:
          type: integer
  /api/aom-tincan-fake/v1/statements:
    put:
      summary: 'Get fake Tin Can state'
      operationId: getFakeTinCanState
      description: 'Returns a JSON response of true.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  success: true
                properties:
                  success:
                    type: boolean
                    example: true
      tags:
        - 'SCORMs '
      security: []
    parameters:
      -
        in: path
        name: modulesStatusId
        description: 'ID of the module status you want to update the Tin Can state of.'
        example: 18
        required: true
        schema:
          type: integer
  /api/aom-tincan/v1/activities/state:
    get:
      summary: 'Get TinCan (xAPI) state for a module in a course registration.'
      operationId: getTinCanxAPIStateForAModuleInACourseRegistration
      description: "This endpoint retrieves the SCORM/xAPI state (like suspend_data or other tracking keys)\nfor a specific module within a registered course. The state is retrieved based on the\n`stateId` and a given registration string."
      parameters:
        -
          in: query
          name: stateId
          description: 'The key/state ID to retrieve (e.g., suspend_data).'
          example: suspend_data
          required: true
          schema:
            type: string
            description: 'The key/state ID to retrieve (e.g., suspend_data).'
            example: suspend_data
        -
          in: query
          name: activityId
          description: 'The activity ID of the xAPI object.'
          example: 'http://example.com/activity'
          required: true
          schema:
            type: string
            description: 'The activity ID of the xAPI object.'
            example: 'http://example.com/activity'
        -
          in: query
          name: registration
          description: 'Pipe-separated values: registrationId|moduleId|packageId.'
          example: 123|456|789
          required: true
          schema:
            type: string
            description: 'Pipe-separated values: registrationId|moduleId|packageId.'
            example: 123|456|789
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  suspend_data: c2Vzc2lvbl9zdGF0ZT0yMDE=
                  progress: 75%
                  lesson_status: incomplete
                properties:
                  suspend_data:
                    type: string
                    example: c2Vzc2lvbl9zdGF0ZT0yMDE=
                  progress:
                    type: string
                    example: 75%
                  lesson_status:
                    type: string
                    example: incomplete
        404:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Course registration or module not found.'
                properties:
                  message:
                    type: string
                    example: 'Course registration or module not found.'
      tags:
        - 'SCORMs '
      security: []
    put:
      summary: 'Update TinCan (xAPI) state for a module in a course registration.'
      operationId: updateTinCanxAPIStateForAModuleInACourseRegistration
      description: "This endpoint allows updating a SCORM/xAPI state value (e.g., suspend_data or lesson_status)\nfor a specific module within a course registration. If a state already exists, it will be updated;\notherwise, a new state record will be created."
      parameters:
        -
          in: query
          name: stateId
          description: 'The key/state ID to update.'
          example: suspend_data
          required: true
          schema:
            type: string
            description: 'The key/state ID to update.'
            example: suspend_data
        -
          in: query
          name: activityId
          description: 'The activity ID of the xAPI object.'
          example: 'http://example.com/activity'
          required: true
          schema:
            type: string
            description: 'The activity ID of the xAPI object.'
            example: 'http://example.com/activity'
        -
          in: query
          name: registration
          description: 'Pipe-separated values: registrationId|moduleId|packageId.'
          example: 123|456|789
          required: true
          schema:
            type: string
            description: 'Pipe-separated values: registrationId|moduleId|packageId.'
            example: 123|456|789
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: boolean
                example: true
        404:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Course registration or module not found.'
                properties:
                  message:
                    type: string
                    example: 'Course registration or module not found.'
      tags:
        - 'SCORMs '
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                string:
                  type: required
                  description: 'Raw SCORM/xAPI value to store in the state.'
                  example: '{"score":85,"lesson_status":"completed"}'
      security: []
  /api/aom-tincan/v1/statements:
    put:
      summary: 'Save TinCan (xAPI) statement for course progress tracking.'
      operationId: saveTinCanxAPIStatementForCourseProgressTracking
      description: "This endpoint accepts and stores xAPI statements sent by a learning module. It handles different types\nof verbs like `attempted`, `completed`, `passed`, `failed`, and `answered`, and processes scoring, progress,\nand interactions accordingly."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: boolean
                example: true
      tags:
        - 'SCORMs '
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                verb:
                  type: object
                  description: 'The verb of the xAPI statement.'
                  example:
                    id: 'http://adlnet.gov/expapi/verbs/completed'
                  properties: {  }
                context:
                  type: object
                  description: ''
                  example:
                    registration: 123|456|789|10
                  properties:
                    registration:
                      type: string
                      description: 'A pipe-separated string containing registrationId, moduleId, packageId, and portalId.'
                      example: 123|456|789|10
                object:
                  type: object
                  description: 'The object of the statement containing details about the learning activity.'
                  example: []
                  properties: {  }
                result:
                  type: object
                  description: 'The result of the statement, such as scores and success.'
                  example:
                    score:
                      raw: 90
                      max: 100
                    success: true
                    completion: true
                  properties: {  }
                timestamp:
                  type: string
                  description: 'The timestamp of when the interaction happened.'
                  example: '2024-05-01T10:00:00Z'
              required:
                - verb
                - object
      security: []
  /api/modules/scorm:
    get:
      summary: 'SCORM Modules Tabular List'
      operationId: sCORMModulesTabularList
      description: "Returns all the SCORM modules in a tabular list format in paginated mode.\nYou can apply filter using search_param via moduleTypes(module type), associatedCourse(modules used in course) and moduleName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"moduleTypes": ["scorm"],associatedCourse:"",moduleName:""}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"moduleTypes": ["scorm"],associatedCourse:"",moduleName:""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      name: test
                      slug: test
                      type: scorm
                      icon: '<i class="el-icon-document"></i>'
                      author: 'Aom Staff'
                      created_at: 'Aug 03, 2020 09:56 AM'
                      course_count: 1
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: test
                        slug: test
                        type: scorm
                        icon: '<i class="el-icon-document"></i>'
                        author: 'Aom Staff'
                        created_at: 'Aug 03, 2020 09:56 AM'
                        course_count: 1
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: test
                        slug:
                          type: string
                          example: test
                        type:
                          type: string
                          example: scorm
                        icon:
                          type: string
                          example: '<i class="el-icon-document"></i>'
                        author:
                          type: string
                          example: 'Aom Staff'
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        course_count:
                          type: integer
                          example: 1
      tags:
        - 'SCORMs '
      security: []
    post:
      summary: 'Create SCORM Module'
      operationId: createSCORMModule
      description: "This function creates a new SCORM module with the provided details.\nIt validates the request, saves module details, and associates categories."
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - 'SCORMs '
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: required
                  description: 'The name of the SCORM module.'
                  example: 'New Scorm Module'
                trackCompletion:
                  type: required
                  description: 'Boolean indicating if the module should track completion.'
                  example: 'true'
                scormPackageId:
                  type: required
                  description: 'The ID of the SCORM package.'
                  example: '1'
                launchNewWindow:
                  type: required
                  description: 'Boolean indicating if the module should launch in a new window.'
                  example: 'true'
                categories:
                  type: array|nullable
                  description: 'Array of category IDs or names associated with the module.'
                  example: '[1, "New Category"]'
                estimatedCompletion:
                  type: int|nullable
                  description: 'Estimated time to complete the module in minutes.'
                  example: '10'
                estimationCompletedUnit:
                  type: string|nullable
                  description: 'Unit of the estimated time to complete the module.'
                  example: minutes
      security: []
  '/api/modules/scorm/{id}':
    put:
      summary: 'Update SCORM Module'
      operationId: updateSCORMModule
      description: "This function updates an existing SCORM module with the provided details.\nIt validates the request, saves module details, and associates categories."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Module updated successfully'
      tags:
        - 'SCORMs '
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'The ID of the SCORM module you want to update.'
                  example: '1'
                name:
                  type: required
                  description: 'The name of the SCORM module.'
                  example: 'Updated Scorm Module'
                trackCompletion:
                  type: required
                  description: 'Boolean indicating if the module should track completion.'
                  example: 'true'
                launchNewWindow:
                  type: required
                  description: 'Boolean indicating if the module should launch in a new window.'
                  example: 'true'
                scormPackageId:
                  type: required
                  description: 'The ID of the SCORM package.'
                  example: '1'
                categories:
                  type: array|nullable
                  description: 'Array of category IDs or names associated with the module.'
                  example: '[1, "New Category"]'
                estimatedCompletion:
                  type: int|nullable
                  description: 'Estimated time to complete the module in minutes.'
                  example: '10'
                estimationCompletedUnit:
                  type: string|nullable
                  description: 'Unit of the estimated time to complete the module.'
                  example: minutes
      security: []
    get:
      summary: 'Get Scorm Module'
      operationId: getScormModule
      description: "Fetch the details of a specified scorm module. (See parameters)\nScorm modules can be used in the course as course content/lesson."
      parameters:
        -
          in: query
          name: id
          description: 'ID of the scorm module you want to fetch the details of.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the scorm module you want to fetch the details of.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: 'New Scorm'
                  slug: new-scorm
                  trackCompletion: true
                  launchNewWindow: false
                  scormPackageId: 1
                  scormPackageFullUrl: 'https://aomlms.com/scorm/sample-course/scormcontent/index.html'
                  scormProxyUrl: 'https://aomlms.com/scorm-proxy'
                  estimatedCompletion: null
                  estimationCompletedUnit: null
                  categories:
                    - 1
                    - 2
                    - 3
                  courses:
                    -
                      course_id: 1
                      course_name: Testing
                    -
                      course_id: 2
                      course_name: 'Testing 2'
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: 'New Scorm'
                  slug:
                    type: string
                    example: new-scorm
                  trackCompletion:
                    type: boolean
                    example: true
                  launchNewWindow:
                    type: boolean
                    example: false
                  scormPackageId:
                    type: integer
                    example: 1
                  scormPackageFullUrl:
                    type: string
                    example: 'https://aomlms.com/scorm/sample-course/scormcontent/index.html'
                  scormProxyUrl:
                    type: string
                    example: 'https://aomlms.com/scorm-proxy'
                  estimatedCompletion:
                    type: string
                    example: null
                  estimationCompletedUnit:
                    type: string
                    example: null
                  categories:
                    type: array
                    example:
                      - 1
                      - 2
                      - 3
                    items:
                      type: integer
                  courses:
                    type: array
                    example:
                      -
                        course_id: 1
                        course_name: Testing
                      -
                        course_id: 2
                        course_name: 'Testing 2'
                    items:
                      type: object
                      properties:
                        course_id:
                          type: integer
                          example: 1
                        course_name:
                          type: string
                          example: Testing
      tags:
        - 'SCORMs '
      security: []
  /api/module/scorm/details:
    get:
      summary: 'Retrieve Detailed Scorm Module Info'
      operationId: retrieveDetailedScormModuleInfo
      description: "Retrieves detailed information about a SCORM module including its name, slug, content, associated course details,\nSCORM URL, tracking and launching options, and more. It also handles the SCORM package versioning and\ngenerates authorization tokens for xAPI integration if applicable. The function checks and updates the module status,\ncalculates time spent, and fetches SCORM keys for the module."
      parameters:
        -
          in: query
          name: registrationId
          description: 'ID of the course registration for which this module is attached.'
          example: '16'
          required: true
          schema:
            type: string
            description: 'ID of the course registration for which this module is attached.'
            example: '16'
        -
          in: query
          name: moduleId
          description: 'ID of the SCORM module.'
          example: '11'
          required: true
          schema:
            type: string
            description: 'ID of the SCORM module.'
            example: '11'
        -
          in: query
          name: portalId
          description: 'optional ID of the portal for course launch URL.'
          example: '5'
          required: false
          schema:
            type: string
            description: 'optional ID of the portal for course launch URL.'
            example: '5'
        -
          in: query
          name: openInNewWindow
          description: 'optional If true, the module is launched in a new window.'
          example: 'true'
          required: false
          schema:
            type: string
            description: 'optional If true, the module is launched in a new window.'
            example: 'true'
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: '{"name": "Module Name", "slug": "module-slug", "content": "Module content if available", "courseName": "Course Name", "courseSlug": "Course Launch URL", "packageId": 1, "scormUrl": "https://scorm.url", "scormProxyUrl": "https://scorm-proxy.url", "version": "SCORM Version", "trackCompletion": true, "launchNewWindow": false, "min_time_spent": 0, "otherModules": [], "launchCheck": {...}, "prevSlug": "previous-module-slug", "nextSlug": "next-module-slug", "scormKeys": {...}, "status": "In Progress", "statusRowId": 19, "timeSpent": 13, "course_newly_completed": false, "timeToBeSpent": 0}'
      tags:
        - 'SCORMs '
      security: []
  /api/scorm-report:
    get:
      summary: 'Get scorm module report details'
      operationId: getScormModuleReportDetails
      description: 'Returns the scorm module report details for the given module status id.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  moduleName: 'Sample Scorm'
                  moduleId: 1
                  score: 100
                  studentName: 'Aom Staff'
                  interactions:
                    -
                      slide: '1'
                      question: 'What is your name?'
                      questionType: text
                      studentResponse: 'John Doe'
                      correctResponse: ''
                      result: correct
                      time: '2022-01-01 12:00:00 PM'
                    -
                      slide: '2'
                      question: 'What is your email?'
                      questionType: text
                      studentResponse: john.doe@example.com
                      correctResponse: ''
                      result: correct
                      time: '2022-01-01 12:00:00 PM'
                  courseId: 1
                  courseName: 'Sample Course'
                properties:
                  moduleName:
                    type: string
                    example: 'Sample Scorm'
                  moduleId:
                    type: integer
                    example: 1
                  score:
                    type: integer
                    example: 100
                  studentName:
                    type: string
                    example: 'Aom Staff'
                  interactions:
                    type: array
                    example:
                      -
                        slide: '1'
                        question: 'What is your name?'
                        questionType: text
                        studentResponse: 'John Doe'
                        correctResponse: ''
                        result: correct
                        time: '2022-01-01 12:00:00 PM'
                      -
                        slide: '2'
                        question: 'What is your email?'
                        questionType: text
                        studentResponse: john.doe@example.com
                        correctResponse: ''
                        result: correct
                        time: '2022-01-01 12:00:00 PM'
                    items:
                      type: object
                      properties:
                        slide:
                          type: string
                          example: '1'
                        question:
                          type: string
                          example: 'What is your name?'
                        questionType:
                          type: string
                          example: text
                        studentResponse:
                          type: string
                          example: 'John Doe'
                        correctResponse:
                          type: string
                          example: ''
                        result:
                          type: string
                          example: correct
                        time:
                          type: string
                          example: '2022-01-01 12:00:00 PM'
                  courseId:
                    type: integer
                    example: 1
                  courseName:
                    type: string
                    example: 'Sample Course'
      tags:
        - 'SCORMs '
      security: []
    parameters:
      -
        in: path
        name: modulesStatusId
        description: 'ID of the module status you want to fetch the report of.'
        example: 12
        required: true
        schema:
          type: integer
      -
        in: path
        name: studentId
        description: 'ID of the student you want to fetch the report for.'
        example: 9
        required: true
        schema:
          type: integer
  /api/scorm-activity-report:
    get:
      summary: 'Get TinCan (xAPI) report for a specific module attempt.'
      operationId: getTinCanxAPIReportForASpecificModuleAttempt
      description: "This endpoint retrieves the TinCan (xAPI) interaction report for a given learner's module status.\nIt includes detailed interaction logs, score calculations, and context information for analysis."
      parameters:
        -
          in: query
          name: modulesStatusId
          description: 'The ID of the module status.'
          example: 42
          required: true
          schema:
            type: integer
            description: 'The ID of the module status.'
            example: 42
        -
          in: query
          name: studentId
          description: 'The ID of the student.'
          example: 2
          required: true
          schema:
            type: integer
            description: 'The ID of the student.'
            example: 2
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  score: 90
                  studentName: 'John Doe'
                  moduleName: 'Workplace Safety 101'
                  interactions:
                    -
                      id: 123
                      modulesStatusId: 42
                      verb: 'http://adlnet.gov/expapi/verbs/completed'
                      activity: Completed
                      objectType: Activity
                      objectName: 'Introduction Slide'
                      statementRaw: null
                      createdBy: 7
                      createdAt: 'April 16, 2025 02:45 PM'
                      message: "You completed 'Introduction Slide'"
                properties:
                  score:
                    type: integer
                    example: 90
                  studentName:
                    type: string
                    example: 'John Doe'
                  moduleName:
                    type: string
                    example: 'Workplace Safety 101'
                  interactions:
                    type: array
                    example:
                      -
                        id: 123
                        modulesStatusId: 42
                        verb: 'http://adlnet.gov/expapi/verbs/completed'
                        activity: Completed
                        objectType: Activity
                        objectName: 'Introduction Slide'
                        statementRaw: null
                        createdBy: 7
                        createdAt: 'April 16, 2025 02:45 PM'
                        message: "You completed 'Introduction Slide'"
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 123
                        modulesStatusId:
                          type: integer
                          example: 42
                        verb:
                          type: string
                          example: 'http://adlnet.gov/expapi/verbs/completed'
                        activity:
                          type: string
                          example: Completed
                        objectType:
                          type: string
                          example: Activity
                        objectName:
                          type: string
                          example: 'Introduction Slide'
                        statementRaw:
                          type: string
                          example: null
                        createdBy:
                          type: integer
                          example: 7
                        createdAt:
                          type: string
                          example: 'April 16, 2025 02:45 PM'
                        message:
                          type: string
                          example: "You completed 'Introduction Slide'"
      tags:
        - 'SCORMs '
      security: []
  /api/scorm-report-pdf:
    get:
      summary: 'Generate SCORM report as PDF'
      operationId: generateSCORMReportAsPDF
      description: "This endpoint generates a PDF report of SCORM interactions and scores for a given module status ID.\nIt includes question responses, time spent, score percentage, and interaction details.\nThe PDF is returned as a downloadable file."
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: 'file binary The downloadable PDF report for the specified SCORM module status.'
      tags:
        - 'SCORMs '
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                modulesStatusId:
                  type: integer
                  description: 'The ID of the module status for which the SCORM report is to be generated.'
                  example: 42
              required:
                - modulesStatusId
      security: []
  /api/module/scorm/content-details:
    get:
      summary: 'Get scorm module content details'
      operationId: getScormModuleContentDetails
      description: 'Returns the scorm module content details.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Sample Scorm'
                  slug: sample-scorm
                  content: 'Sample Scorm Content'
                  scormUrl: 'https://staging.aomlms.com/storage/scorm/sample-course/scormcontent/index.html'
                  scormProxyUrl: 'https://aom-s3-proxy.herokuapp.com'
                  version: '1.2'
                  trackCompletion: true
                  scormKeys:
                    cmi.suspend_data: ''
                    cmi.core.lesson_location: ''
                    cmi.core.lesson_mode: normal
                    cmi.mode: normal
                    cmi.core.lesson_status: incomplete
                    cmi.success_status: ''
                    cmi.completion_status: incomplete
                    cmi.core.student_id: 2
                    cmi.core.student_name: 'Aom Staff'
                    cmi.location: ''
                  timeSpent: '0h 0m'
                properties:
                  name:
                    type: string
                    example: 'Sample Scorm'
                  slug:
                    type: string
                    example: sample-scorm
                  content:
                    type: string
                    example: 'Sample Scorm Content'
                  scormUrl:
                    type: string
                    example: 'https://staging.aomlms.com/storage/scorm/sample-course/scormcontent/index.html'
                  scormProxyUrl:
                    type: string
                    example: 'https://aom-s3-proxy.herokuapp.com'
                  version:
                    type: string
                    example: '1.2'
                  trackCompletion:
                    type: boolean
                    example: true
                  scormKeys:
                    type: object
                    properties:
                      cmi.suspend_data:
                        type: string
                        example: ''
                      cmi.core.lesson_location:
                        type: string
                        example: ''
                      cmi.core.lesson_mode:
                        type: string
                        example: normal
                      cmi.mode:
                        type: string
                        example: normal
                      cmi.core.lesson_status:
                        type: string
                        example: incomplete
                      cmi.success_status:
                        type: string
                        example: ''
                      cmi.completion_status:
                        type: string
                        example: incomplete
                      cmi.core.student_id:
                        type: integer
                        example: 2
                      cmi.core.student_name:
                        type: string
                        example: 'Aom Staff'
                      cmi.location:
                        type: string
                        example: ''
                  timeSpent:
                    type: string
                    example: '0h 0m'
      tags:
        - 'SCORMs '
      security: []
    parameters:
      -
        in: path
        name: moduleId
        description: 'ID of the module you want to fetch the details of.'
        example: 14
        required: true
        schema:
          type: integer
  /api/integrations/salesforce/eventLookup:
    get:
      summary: 'Salesforce Event Lookup'
      operationId: salesforceEventLookup
      description: "Retrieves all the events for the salesforce actions.\nHelps showing options in dropdowns elements"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  events:
                    -
                      db_value: new_account_created
                      display_value: 'New Account Created'
                      crud_op: Create
                      salesforce_crud:
                        -
                          db_value: salesforce_contact
                          display_value: 'Salesforce Contacts'
                    -
                      db_value: account_updated
                      display_value: 'Account Updated'
                      crud_op: Update
                      salesforce_crud:
                        -
                          db_value: salesforce_contact
                          display_value: 'Salesforce Contacts'
                    -
                      db_value: course_enrolled
                      display_value: 'Enrolled in a course'
                      crud_op: Update
                      salesforce_crud:
                        -
                          db_value: salesforce_custom_registration_object
                          display_value: 'Salesforce Custom Course Registration Object'
                    -
                      db_value: course_completed
                      display_value: 'Course Completed'
                      crud_op: Update
                      salesforce_crud:
                        -
                          db_value: salesforce_custom_registration_object
                          display_value: 'Salesforce Custom Course Registration Object'
                    -
                      db_value: course_started
                      display_value: 'Course Started'
                      crud_op: Update
                      salesforce_crud:
                        -
                          db_value: salesforce_custom_registration_object
                          display_value: 'Salesforce Custom Course Registration Object'
                    -
                      db_value: course_progress
                      display_value: 'Course Progress Tracking'
                      crud_op: Update
                      salesforce_crud:
                        -
                          db_value: salesforce_custom_registration_object
                          display_value: 'Salesforce Custom Course Registration Object'
                properties:
                  events:
                    type: array
                    example:
                      -
                        db_value: new_account_created
                        display_value: 'New Account Created'
                        crud_op: Create
                        salesforce_crud:
                          -
                            db_value: salesforce_contact
                            display_value: 'Salesforce Contacts'
                      -
                        db_value: account_updated
                        display_value: 'Account Updated'
                        crud_op: Update
                        salesforce_crud:
                          -
                            db_value: salesforce_contact
                            display_value: 'Salesforce Contacts'
                      -
                        db_value: course_enrolled
                        display_value: 'Enrolled in a course'
                        crud_op: Update
                        salesforce_crud:
                          -
                            db_value: salesforce_custom_registration_object
                            display_value: 'Salesforce Custom Course Registration Object'
                      -
                        db_value: course_completed
                        display_value: 'Course Completed'
                        crud_op: Update
                        salesforce_crud:
                          -
                            db_value: salesforce_custom_registration_object
                            display_value: 'Salesforce Custom Course Registration Object'
                      -
                        db_value: course_started
                        display_value: 'Course Started'
                        crud_op: Update
                        salesforce_crud:
                          -
                            db_value: salesforce_custom_registration_object
                            display_value: 'Salesforce Custom Course Registration Object'
                      -
                        db_value: course_progress
                        display_value: 'Course Progress Tracking'
                        crud_op: Update
                        salesforce_crud:
                          -
                            db_value: salesforce_custom_registration_object
                            display_value: 'Salesforce Custom Course Registration Object'
                    items:
                      type: object
                      properties:
                        db_value:
                          type: string
                          example: new_account_created
                        display_value:
                          type: string
                          example: 'New Account Created'
                        crud_op:
                          type: string
                          example: Create
                        salesforce_crud:
                          type: array
                          example:
                            -
                              db_value: salesforce_contact
                              display_value: 'Salesforce Contacts'
                          items:
                            type: object
                            properties:
                              db_value:
                                type: string
                                example: salesforce_contact
                              display_value:
                                type: string
                                example: 'Salesforce Contacts'
      tags:
        - 'Salesforce Integration'
      security: []
  /api/integrations/salesforce/fieldLookup:
    get:
      summary: 'Field Lookup'
      operationId: fieldLookup
      description: "Retrieves all the fields for the given object type - contact or custom_course_object.\nHelps showing options in dropdowns elements"
      parameters:
        -
          in: query
          name: type
          description: 'The object type - contact or custom_course_object.'
          example: contact
          required: true
          schema:
            type: string
            description: 'The object type - contact or custom_course_object.'
            example: contact
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  lms_fields:
                    -
                      db_value: email
                    -
                      db_value: last_name
                    -
                      db_value: first_name
                    -
                      db_value: last_login_ip
                    -
                      db_value: is_disabled
                  salesforce_fields:
                    -
                      db_value: email
                    -
                      db_value: lastName
                    -
                      db_value: firstName
                  courses:
                    -
                      id: 1
                      name: 'Course 1'
                    -
                      id: 2
                      name: 'Course 2'
                properties:
                  lms_fields:
                    type: array
                    example:
                      -
                        db_value: email
                      -
                        db_value: last_name
                      -
                        db_value: first_name
                      -
                        db_value: last_login_ip
                      -
                        db_value: is_disabled
                    items:
                      type: object
                      properties:
                        db_value:
                          type: string
                          example: email
                  salesforce_fields:
                    type: array
                    example:
                      -
                        db_value: email
                      -
                        db_value: lastName
                      -
                        db_value: firstName
                    items:
                      type: object
                      properties:
                        db_value:
                          type: string
                          example: email
                  courses:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Course 1'
                      -
                        id: 2
                        name: 'Course 2'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Course 1'
      tags:
        - 'Salesforce Integration'
      security: []
  /api/salesforces:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the salesforce integrations in a tabular list format in paginated mode.\nYou can apply filter using search_param via events(salesforce integration events)."
      parameters:
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName": "name", "direction": "asc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName": "name", "direction": "asc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: 0
          required: false
          schema:
            type: integer
            description: 'for searching items based on field names.'
            example: 0
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      event: course_enrolled
                      event_display_value: 'Enrolled in a Course'
                      object: salesforce_contact
                      object_display_value: 'Salesforce Contact'
                      action: created
                      author: 'John Doe'
                      created_at: '2021-01-01 12:00:00'
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        event: course_enrolled
                        event_display_value: 'Enrolled in a Course'
                        object: salesforce_contact
                        object_display_value: 'Salesforce Contact'
                        action: created
                        author: 'John Doe'
                        created_at: '2021-01-01 12:00:00'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        event:
                          type: string
                          example: course_enrolled
                        event_display_value:
                          type: string
                          example: 'Enrolled in a Course'
                        object:
                          type: string
                          example: salesforce_contact
                        object_display_value:
                          type: string
                          example: 'Salesforce Contact'
                        action:
                          type: string
                          example: created
                        author:
                          type: string
                          example: 'John Doe'
                        created_at:
                          type: string
                          example: '2021-01-01 12:00:00'
      tags:
        - 'Salesforce Integration'
      security: []
  /api/salesforce/action/create:
    post:
      summary: 'Create Salesforce Action'
      operationId: createSalesforceAction
      description: 'To create a Salesforce Action, you need to use this request. Provide event, action and object and it will be created. (See parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Action created Successfully'
                properties:
                  message:
                    type: string
                    example: 'Action created Successfully'
      tags:
        - 'Salesforce Integration'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                event:
                  type: string
                  description: 'Event for which you want to create action.'
                  example: course_enrolled
                action:
                  type: string
                  description: 'Action will be create of the event by default.'
                  example: create.
                object:
                  type: string
                  description: 'Select the object from the dropdown list from Salesforce contact.'
                  example: salesforce_contact
              required:
                - event
                - action
                - object
      security: []
  /api/salesforce/mapping/save:
    post:
      summary: 'Save Salesforce Mapping'
      operationId: saveSalesforceMapping
      description: 'Saves the mapping of salesforce mapping. Helps in saving salesforce mapping using its type. (See Parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: true
                  message: 'Mapping saved Successfully'
                properties:
                  is_success:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Mapping saved Successfully'
      tags:
        - 'Salesforce Integration'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                type:
                  type: required
                  description: 'Type of the salesforce mapping you want to save the details of.'
                  example: salesforce_contact
      security: []
  /api/salesforce/mappings:
    get:
      summary: 'Retrieve Salesforce Mapping'
      operationId: retrieveSalesforceMapping
      description: 'Retrieves the details of the salesforce mapping. Helps in fetching salesforce mapping using its type. (See Parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  type: salesforce_course_and_registration_custom_object
                  courseFieldProperties: []
                  courseRegistrationFieldProperties: []
                  sfCustomObjectNames: []
                  isSyncCourseCompleted: true
                properties:
                  type:
                    type: string
                    example: salesforce_course_and_registration_custom_object
                  courseFieldProperties:
                    type: array
                    example: []
                  courseRegistrationFieldProperties:
                    type: array
                    example: []
                  sfCustomObjectNames:
                    type: array
                    example: []
                  isSyncCourseCompleted:
                    type: boolean
                    example: true
      tags:
        - 'Salesforce Integration'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                type:
                  type: required
                  description: 'Type of the salesforce mapping you want to fetch the details of.'
                  example: salesforce_contact
      security: []
  '/api/salesforce/{id}':
    put:
      summary: 'Update Salesforce Action'
      operationId: updateSalesforceAction
      description: 'Updates a Salesforce action based on the provided ID.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Salesforce updated successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Salesforce updated successfully'
      tags:
        - 'Salesforce Integration'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                event:
                  type: required
                  description: 'The event of the Salesforce action.'
                  example: 'New Account Created'
                action:
                  type: required
                  description: 'The action of the Salesforce action.'
                  example: create
                object:
                  type: required
                  description: 'The object of the Salesforce action.'
                  example: 'Salesforce Contact'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the Salesforce action to be updated.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/salesforce/action/delete/{id}':
    post:
      summary: 'Delete Salesforce Action'
      operationId: deleteSalesforceAction
      description: 'To delete a Salesforce Action, you need to use this request. Provide id and it will be deleted. (See parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Salesforce deleted successfully'
                properties:
                  message:
                    type: string
                    example: 'Salesforce deleted successfully'
      tags:
        - 'Salesforce Integration'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the salesforce action.'
        example: '3'
        required: true
        schema:
          type: string
  '/api/salesforce/logs/{id}':
    get:
      summary: 'Retrieves Salesforce logs in a paginated format.'
      operationId: retrievesSalesforceLogsInAPaginatedFormat
      description: "This function returns logs related to a specific Salesforce action identified by its ID.\nThe logs are presented in a tabular format, allowing pagination and optional sorting."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of items per page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of items per page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'The current page number for pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number for pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'Optional parameter for sorting items based on columns in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'Optional parameter for sorting items based on columns in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 100
                  recordsFiltered: 50
                  records:
                    -
                      id: 1
                      event: 'New Account Created'
                      data: []
                      status: success
                      display_status: Success
                      errorMessage: ''
                      created_at: 'Aug 03, 2020 09:56 AM'
                      showData: false
                properties:
                  recordsTotal:
                    type: integer
                    example: 100
                  recordsFiltered:
                    type: integer
                    example: 50
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        event: 'New Account Created'
                        data: []
                        status: success
                        display_status: Success
                        errorMessage: ''
                        created_at: 'Aug 03, 2020 09:56 AM'
                        showData: false
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        event:
                          type: string
                          example: 'New Account Created'
                        data:
                          type: array
                          example: []
                        status:
                          type: string
                          example: success
                        display_status:
                          type: string
                          example: Success
                        errorMessage:
                          type: string
                          example: ''
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        showData:
                          type: boolean
                          example: false
      tags:
        - 'Salesforce Integration'
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the Salesforce action whose logs are to be retrieved.'
        example: '50'
        required: true
        schema:
          type: string
  /api/staffs/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the staffs in a tabular list format with pagination mode.\nYou can apply filter using search_param via name or email."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the users you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the users you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on name, email.'
          example: '{"nameOrEmail":"John Doe","membershipId":1}'
          required: false
          schema:
            type: string
            description: 'for searching items based on name, email.'
            example: '{"nameOrEmail":"John Doe","membershipId":1}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 4
                  recordsFiltered: 4
                  records:
                    -
                      id: 4
                      first_name: John
                      last_name: Doe
                      email: john@aom.com
                      avatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#03A9F4"/><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">JD</text></svg>'
                      user_type: general
                      display_user_type: General
                      created_at: 'Aug 06, 2020 07:20 AM'
                      last_login: '2 days ago'
                properties:
                  recordsTotal:
                    type: integer
                    example: 4
                  recordsFiltered:
                    type: integer
                    example: 4
                  records:
                    type: array
                    example:
                      -
                        id: 4
                        first_name: John
                        last_name: Doe
                        email: john@aom.com
                        avatar: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#03A9F4"/><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">JD</text></svg>'
                        user_type: general
                        display_user_type: General
                        created_at: 'Aug 06, 2020 07:20 AM'
                        last_login: '2 days ago'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 4
                        first_name:
                          type: string
                          example: John
                        last_name:
                          type: string
                          example: Doe
                        email:
                          type: string
                          example: john@aom.com
                        avatar:
                          type: string
                          example: '<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><circle cx="20" cy="20" r="20" stroke="background" stroke-width="0" fill="#03A9F4"/><text x="20" y="20" font-size="14" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">JD</text></svg>'
                        user_type:
                          type: string
                          example: general
                        display_user_type:
                          type: string
                          example: General
                        created_at:
                          type: string
                          example: 'Aug 06, 2020 07:20 AM'
                        last_login:
                          type: string
                          example: '2 days ago'
      tags:
        - Staffs
      security: []
  /api/staff/report:
    get:
      summary: 'Retrieves detailed report for all staffs.'
      operationId: retrievesDetailedReportForAllStaffs
      description: ''
      parameters:
        -
          in: query
          name: page_size
          description: 'Number of the result row you want in each page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'Number of the result row you want in each page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current Page number.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current Page number.'
            example: '1'
        -
          in: query
          name: registered_between
          description: 'Returns search filtered data.'
          example: '{"first_name":"John","last_name":"Doe"}'
          required: false
          schema:
            type: string
            description: 'Returns search filtered data.'
            example: '{"first_name":"John","last_name":"Doe"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  totalNotStarted: 1
                  totalInProgress: 0
                  totalCompleted: 0
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      first_name: John
                      last_name: Doe
                      email: john@aom.com
                      user_type: General
                      created_at: 'Aug 09, 2020'
                      last_login: 'Oct 09, 2020'
                properties:
                  totalNotStarted:
                    type: integer
                    example: 1
                  totalInProgress:
                    type: integer
                    example: 0
                  totalCompleted:
                    type: integer
                    example: 0
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        first_name: John
                        last_name: Doe
                        email: john@aom.com
                        user_type: General
                        created_at: 'Aug 09, 2020'
                        last_login: 'Oct 09, 2020'
                    items:
                      type: object
                      properties:
                        first_name:
                          type: string
                          example: John
                        last_name:
                          type: string
                          example: Doe
                        email:
                          type: string
                          example: john@aom.com
                        user_type:
                          type: string
                          example: General
                        created_at:
                          type: string
                          example: 'Aug 09, 2020'
                        last_login:
                          type: string
                          example: 'Oct 09, 2020'
      tags:
        - Staffs
      security: []
  /api/staff/create:
    post:
      summary: 'Creates a new staff member.'
      operationId: createsANewStaffMember
      description: ''
      parameters:
        -
          in: query
          name: firstName
          description: 'First name of the staff.'
          example: John
          required: true
          schema:
            type: string
            description: 'First name of the staff.'
            example: John
        -
          in: query
          name: lastName
          description: 'Last name of the staff.'
          example: Doe
          required: true
          schema:
            type: string
            description: 'Last name of the staff.'
            example: Doe
        -
          in: query
          name: email
          description: 'Email of the staff.'
          example: john.doe@example.com
          required: true
          schema:
            type: string
            description: 'Email of the staff.'
            example: john.doe@example.com
        -
          in: query
          name: password
          description: 'Password for the staff. Must be at least 8 characters long and should not have been compromised according to the haveibeenpwned.com API.'
          example: Nv10=80l^
          required: true
          schema:
            type: string
            description: 'Password for the staff. Must be at least 8 characters long and should not have been compromised according to the haveibeenpwned.com API.'
            example: Nv10=80l^
        -
          in: query
          name: staffPermissions
          description: 'if userType is set to staff. Array of permission IDs to assign to the staff.'
          example: '[1,2,3]'
          required: true
          schema:
            type: string
            description: 'if userType is set to staff. Array of permission IDs to assign to the staff.'
            example: '[1,2,3]'
        -
          in: query
          name: userType
          description: 'Type of the user to create.'
          example: staff
          required: true
          schema:
            type: string
            description: 'Type of the user to create.'
            example: staff
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Staff created successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Staff created successfully'
      tags:
        - Staffs
      security: []
  '/api/staff/{id}':
    get:
      summary: 'Retrieve Staff By ID'
      operationId: retrieveStaffByID
      description: 'This endpoint returns the staff details based on the ID specified.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  firstName: John
                  lastName: Doe
                  email: john@aom.com
                  lastLoggedIn: '2 hours ago'
                  avatar: '<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><circle cx="50" cy="50" r="50" stroke="background" stroke-width="0" fill="#03A9F4" /><text x="50" y="50" font-size="40" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">JD</text></svg>'
                  disabled: false
                  userType: staff
                  currentLoggedUserType: owner
                  membership:
                    id: 1
                    name: Silver
                    expiryDate: null
                  customUserMetas:
                    full_name:
                      type: text
                      label: 'Full Name'
                      submitted_value: 'John Doe'
                      placeholder_value: ''
                    user_type:
                      type: dropdown
                      label: 'User Type'
                      submitted_value: 1
                      placeholder_value: ''
                      option_label:
                        - Staff
                        - Owner
                      option_value:
                        - 1
                        - 2
                  internal_note: null
                properties:
                  id:
                    type: integer
                    example: 1
                  firstName:
                    type: string
                    example: John
                  lastName:
                    type: string
                    example: Doe
                  email:
                    type: string
                    example: john@aom.com
                  lastLoggedIn:
                    type: string
                    example: '2 hours ago'
                  avatar:
                    type: string
                    example: '<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><circle cx="50" cy="50" r="50" stroke="background" stroke-width="0" fill="#03A9F4" /><text x="50" y="50" font-size="40" fill="#FFFFFF" alignment-baseline="middle" text-anchor="middle" dominant-baseline="central">JD</text></svg>'
                  disabled:
                    type: boolean
                    example: false
                  userType:
                    type: string
                    example: staff
                  currentLoggedUserType:
                    type: string
                    example: owner
                  membership:
                    type: object
                    properties:
                      id:
                        type: integer
                        example: 1
                      name:
                        type: string
                        example: Silver
                      expiryDate:
                        type: string
                        example: null
                  customUserMetas:
                    type: object
                    properties:
                      full_name:
                        type: object
                        properties:
                          type:
                            type: string
                            example: text
                          label:
                            type: string
                            example: 'Full Name'
                          submitted_value:
                            type: string
                            example: 'John Doe'
                          placeholder_value:
                            type: string
                            example: ''
                      user_type:
                        type: object
                        properties:
                          type:
                            type: string
                            example: dropdown
                          label:
                            type: string
                            example: 'User Type'
                          submitted_value:
                            type: integer
                            example: 1
                          placeholder_value:
                            type: string
                            example: ''
                          option_label:
                            type: array
                            example:
                              - Staff
                              - Owner
                            items:
                              type: string
                          option_value:
                            type: array
                            example:
                              - 1
                              - 2
                            items:
                              type: integer
                  internal_note:
                    type: string
                    example: null
      tags:
        - Staffs
      security: []
    put:
      summary: 'Update Staff/Owner details'
      operationId: updateStaffOwnerDetails
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Owner/Staff updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Owner/Staff updated successfully'
      tags:
        - Staffs
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'The ID of the staff to update.'
                  example: '2'
                firstName:
                  type: required
                  description: 'First name of the staff.'
                  example: John
                lastName:
                  type: required
                  description: 'Last name of the staff.'
                  example: Doe
                email:
                  type: required
                  description: 'Email of the staff.'
                  example: john.doe@example.com
                disabled:
                  type: required
                  description: 'boolean whether the staff is disabled or not.'
                  example: '0'
                internal_note:
                  type: optional
                  description: 'Internal note for the staff.'
                  example: 'This is a note.'
                customUserMetas:
                  type: optional
                  description: 'Custom user meta fields.'
                  example: '{"meta_key1":{"type":"text","submitted_value":"value1"},"meta_key2":{"type":"checkbox","submitted_value":[1,2,3]}}'
                userType:
                  type: required
                  description: 'Type of the user to update.'
                  example: staff
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the staff.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/staff/permissions/{id}':
    get:
      summary: 'Get Staff Permissions'
      operationId: getStaffPermissions
      description: 'Returns all permissions for the staff'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  permissions: []
                properties:
                  permissions:
                    type: array
                    example: []
      tags:
        - Staffs
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'Optional parameter. The ID of the staff. Exmaple: 2'
        required: true
        schema:
          type: integer
        examples:
          omitted:
            summary: 'When the value is omitted'
            value: ''
          present:
            summary: 'When the value is present'
            value: 16
  '/api/staff/updatePermission/{id}':
    put:
      summary: 'Update Staff Permissions'
      operationId: updateStaffPermissions
      description: 'Update the permissions of a staff member'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Permissions updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Permissions updated successfully'
      tags:
        - Staffs
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                permissions:
                  type: array
                  description: 'The permissions for the staff.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - permissions
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the staff.'
        example: '1'
        required: true
        schema:
          type: string
  '/api/subscription/{id}':
    get:
      summary: 'Retrieve Subscription'
      operationId: retrieveSubscription
      description: "To retrieve a subscription, you need to use this request. (See parameters)\n\nReturns :  success status and successfull message"
      parameters:
        -
          in: query
          name: id
          description: 'Subscription ID of the subscription.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Subscription ID of the subscription.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: ACTIVE
                  endDate: '2020-10-01 00:00:00'
                  nextPaymentDate: '2020-10-01 00:00:00'
                  userName: 'John Doe (#1 - john@example.com)'
                  paymentGatewayId: 1
                properties:
                  status:
                    type: string
                    example: ACTIVE
                  endDate:
                    type: string
                    example: '2020-10-01 00:00:00'
                  nextPaymentDate:
                    type: string
                    example: '2020-10-01 00:00:00'
                  userName:
                    type: string
                    example: 'John Doe (#1 - john@example.com)'
                  paymentGatewayId:
                    type: integer
                    example: 1
      tags:
        - 'Subscription Products'
      security: []
    put:
      summary: 'Update Subscription'
      operationId: updateSubscription
      description: "To update a subscription, you need to use this request. (See parameters)\nSubscription can be only created by purchasing subscription product.\n\nReturns :  success status and successfull message"
      parameters:
        -
          in: query
          name: id
          description: 'Subscription ID of the subscription.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Subscription ID of the subscription.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Subscription updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Subscription updated successfully'
      tags:
        - 'Subscription Products'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                status:
                  type: required
                  description: 'Status of the subscription.'
                  example: ACTIVE
                endDate:
                  type: nullable
                  description: 'End date of the subscription.'
                  example: '2020-10-01 00:00:00'
                nextPaymentDate:
                  type: required
                  description: 'Next payment date of the subscription.'
                  example: '2020-10-01 00:00:00'
      security: []
  /api/subscription/product/related:
    get:
      summary: 'Retrieves the product details for a given subscription id.'
      operationId: retrievesTheProductDetailsForAGivenSubscriptionId
      description: 'Returns product title, price, and image url.'
      parameters:
        -
          in: query
          name: id
          description: 'The subscription id whose product details you want to retrieve.'
          example: laudantium
          required: true
          schema:
            type: string
            description: 'The subscription id whose product details you want to retrieve.'
            example: laudantium
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  product_id: 1
                  title: 'Product 1'
                  subscription_price: '$10.00 / month'
                  product_image_url: 'https://example.com/product-1.jpg'
                properties:
                  product_id:
                    type: integer
                    example: 1
                  title:
                    type: string
                    example: 'Product 1'
                  subscription_price:
                    type: string
                    example: '$10.00 / month'
                  product_image_url:
                    type: string
                    example: 'https://example.com/product-1.jpg'
      tags:
        - 'Subscription Products'
      security: []
  /api/subscription/orders/tabularlist:
    get:
      summary: 'Retrieves the related orders of a given subscription id.'
      operationId: retrievesTheRelatedOrdersOfAGivenSubscriptionId
      description: ''
      parameters:
        -
          in: query
          name: subscription_id
          description: 'The subscription id whose related orders you want to retrieve.'
          example: recusandae
          required: true
          schema:
            type: string
            description: 'The subscription id whose related orders you want to retrieve.'
            example: recusandae
        -
          in: query
          name: page_size
          description: 'The amount of records to return per page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The amount of records to return per page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'The page number of the records to return.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The page number of the records to return.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'The order by parameters.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: true
          schema:
            type: string
            description: 'The order by parameters.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'The search parameters.'
          example: '{"orderStatus": ["IN-PROGRESS", "COMPLETED"]}'
          required: true
          schema:
            type: string
            description: 'The search parameters.'
            example: '{"orderStatus": ["IN-PROGRESS", "COMPLETED"]}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      total: 100.0
                      status: IN-PROGRESS
                      relationship: 'Parent Order'
                      created_at: 'Jan 01, 2021 12:00 AM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        total: 100
                        status: IN-PROGRESS
                        relationship: 'Parent Order'
                        created_at: 'Jan 01, 2021 12:00 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        total:
                          type: number
                          example: 100.0
                        status:
                          type: string
                          example: IN-PROGRESS
                        relationship:
                          type: string
                          example: 'Parent Order'
                        created_at:
                          type: string
                          example: 'Jan 01, 2021 12:00 AM'
      tags:
        - 'Subscription Products'
      security: []
  /api/subscription/create:
    post:
      summary: 'Create Subscription'
      operationId: createSubscription
      description: 'Creates a new subscription based on an order, selected subscription products, and optional coupon/payment token.'
      parameters: []
      responses:
        201:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  success: true
                  message: 'Subscription has been created'
                properties:
                  success:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Subscription has been created'
      tags:
        - 'Subscription Products'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                orderId:
                  type: integer
                  description: 'The ID of the order containing the subscription products.'
                  example: 1001
                paymentToken:
                  type: string
                  description: 'Optional token for payment processing.'
                  example: sk_test_abc123
                productQuantity:
                  type: object
                  description: 'A key-value pair of product IDs and their quantities.'
                  example:
                    12: 1
                    15: 2
                  properties: {  }
              required:
                - orderId
                - productQuantity
      security: []
  /api/subscriptions/tabularlist:
    get:
      summary: 'Tabular List'
      operationId: tabularList
      description: "Retrieves all the subscriptions in a tabular list format with pagination mode.\nYou can apply filter using search_param via productTitle, subscriptionStatus(active, cancelled, expired, on-hold), nameOrEmail and subscriptionOrderMonth."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the subscriptions you want for a page.'
          example: '10'
          required: true
          schema:
            type: string
            description: 'The number of the subscriptions you want for a page.'
            example: '10'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at","direction":"desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at","direction":"desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"productTitle": "", "subscriptionStatus": ["ACTIVE", "CANCELLED"], "nameOrEmail": "john@example.com", "subscriptionOrderMonth": "2020-01"}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"productTitle": "", "subscriptionStatus": ["ACTIVE", "CANCELLED"], "nameOrEmail": "john@example.com", "subscriptionOrderMonth": "2020-01"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 10
                  recordsFiltered: 10
                  records:
                    -
                      id: 1
                      user_name: 'John Doe'
                      user_id: 1
                      product: 'Product 1'
                      product_id: 1
                      subscription_price: '$10.00 / month'
                      next_payment_date: 'Jan 01, 2021 12:00 AM'
                      status: ACTIVE
                      created_at: 'Jan 01, 2021 12:00 AM'
                properties:
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 10
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        user_name: 'John Doe'
                        user_id: 1
                        product: 'Product 1'
                        product_id: 1
                        subscription_price: '$10.00 / month'
                        next_payment_date: 'Jan 01, 2021 12:00 AM'
                        status: ACTIVE
                        created_at: 'Jan 01, 2021 12:00 AM'
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        user_name:
                          type: string
                          example: 'John Doe'
                        user_id:
                          type: integer
                          example: 1
                        product:
                          type: string
                          example: 'Product 1'
                        product_id:
                          type: integer
                          example: 1
                        subscription_price:
                          type: string
                          example: '$10.00 / month'
                        next_payment_date:
                          type: string
                          example: 'Jan 01, 2021 12:00 AM'
                        status:
                          type: string
                          example: ACTIVE
                        created_at:
                          type: string
                          example: 'Jan 01, 2021 12:00 AM'
      tags:
        - 'Subscription Products'
      security: []
  /api/subscription/status/lookup:
    get:
      summary: 'Subscription Status Lookup'
      operationId: subscriptionStatusLookup
      description: "Retrieves all the statuses for a subscription the platform offers like Active, Cancelled, Expired, On-Hold.\nHelps showing options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: ACTIVE
                    display_value: Active
                  -
                    db_value: CANCELLED
                    display_value: Cancelled
                  -
                    db_value: EXPIRED
                    display_value: Expired
                  -
                    db_value: ON-HOLD
                    display_value: On-Hold
      tags:
        - 'Subscription Products'
      security: []
  /api/subscription/quickEdit:
    post:
      summary: 'Quick Edit Subscriptions'
      operationId: quickEditSubscriptions
      description: 'Updates the status of the specified subscriptions in bulk.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Subscriptions updated Successfully'
                properties:
                  message:
                    type: string
                    example: 'Subscriptions updated Successfully'
      tags:
        - 'Subscription Products'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                subscription_ids:
                  type: array
                  description: 'The IDs of the subscriptions to be updated.'
                  example:
                    - 1
                    - 2
                  items:
                    type: string
                status:
                  type: string
                  description: 'The new status to set for the subscriptions.'
                  example: '"ACTIVE"'
              required:
                - subscription_ids
                - status
      security: []
  /api/subscription/process-subscription-action:
    post:
      summary: 'Process Subscription Action'
      operationId: processSubscriptionAction
      description: 'Perform a specific action on the subscription like process renewal.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  success: true
                  message: 'Process Renewal Successfully completed'
                properties:
                  success:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Process Renewal Successfully completed'
      tags:
        - 'Subscription Products'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: integer
                  description: 'The ID of the subscription.'
                  example: 1
                action:
                  type: string
                  description: 'The action to perform on the subscription.'
                  example: PROCESS_RENEWAL
              required:
                - id
                - action
      security: []
  /api/subscription/action/lookup:
    get:
      summary: 'Subscription Action Lookup'
      operationId: subscriptionActionLookup
      description: "Retrieves all the actions that can be performed on a subscription like Process renewal.\nHelps showing options in form elements like dropdowns."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    db_value: PROCESS_RENEWAL
                    display_value: 'Process renewal'
                  -
                    db_value: CREATE_PENDING_RENEWAL_ORDER
                    display_value: 'Create pending renewal order'
      tags:
        - 'Subscription Products'
      security: []
  /api/modules/survey:
    get:
      summary: 'Get paginated list of survey modules.'
      operationId: getPaginatedListOfSurveyModules
      description: 'Returns a paginated, searchable, and sortable list of survey-type modules with metadata such as author, course mapping, and timestamps.'
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of records per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'The number of records per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The current page number.'
            example: 1
        -
          in: query
          name: order_by
          description: 'An object containing sorting preferences.'
          example:
            colName: name
            direction: asc
          required: false
          schema:
            type: object
            description: 'An object containing sorting preferences.'
            example:
              colName: name
              direction: asc
            properties: {  }
        -
          in: query
          name: search_param
          description: 'Optional search filters.'
          example: []
          required: false
          schema:
            type: object
            description: 'Optional search filters.'
            example: []
            properties: {  }
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 52
                  recordsFiltered: 7
                  records:
                    -
                      id: 12
                      name: 'Employee Feedback Survey'
                      slug: employee-feedback-survey
                      type: survey
                      icon: fa-poll
                      author: 'Jane Smith'
                      showMappedCourses: false
                      created_at: 'April 15, 2025 03:20 PM'
                      course_count: 3
                properties:
                  recordsTotal:
                    type: integer
                    example: 52
                  recordsFiltered:
                    type: integer
                    example: 7
                  records:
                    type: array
                    example:
                      -
                        id: 12
                        name: 'Employee Feedback Survey'
                        slug: employee-feedback-survey
                        type: survey
                        icon: fa-poll
                        author: 'Jane Smith'
                        showMappedCourses: false
                        created_at: 'April 15, 2025 03:20 PM'
                        course_count: 3
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 12
                        name:
                          type: string
                          example: 'Employee Feedback Survey'
                        slug:
                          type: string
                          example: employee-feedback-survey
                        type:
                          type: string
                          example: survey
                        icon:
                          type: string
                          example: fa-poll
                        author:
                          type: string
                          example: 'Jane Smith'
                        showMappedCourses:
                          type: boolean
                          example: false
                        created_at:
                          type: string
                          example: 'April 15, 2025 03:20 PM'
                        course_count:
                          type: integer
                          example: 3
      tags:
        - 'Survey Modules'
      security: []
    post:
      summary: 'Creates a new survey module'
      operationId: createsANewSurveyModule
      description: 'Creates a new survey module using form fields provided in the request body.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - 'Survey Modules'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the text module.'
                  example: Feedback
                content:
                  type: string
                  description: 'Content for the text modules that learners will see.'
                  example: 'This is the short content here'
                submitButtonText:
                  type: string
                  description: 'Text for the submit button.'
                  example: 'Submit Survey'
                submitOption:
                  type: string
                  description: 'Submission options for learners.'
                  example: save_to_db
                fields:
                  type: array
                  description: 'Form fields inside the Survey form(like radio, dropdown, rating, text, textarea, etc).'
                  example:
                    -
                      type: text
                      label: 'How you left'
                      defaultValue: ''
                      isRequired: false
                      optionLabel: []
                    -
                      type: rating
                      label: 'How you rate us'
                      defaultValue: ''
                      isRequired: false
                      optionLabel: []
                  items:
                    type: string
              required:
                - name
                - submitButtonText
                - submitOption
                - fields
      security: []
  '/api/modules/survey/{id}':
    put:
      summary: 'Update the specified survey module in storage.'
      operationId: updateTheSpecifiedSurveyModuleInStorage
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Module updated successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Module updated successfully'
      tags:
        - 'Survey Modules'
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                id:
                  type: required
                  description: 'The ID of the survey module.'
                  example: '1'
                name:
                  type: required
                  description: 'The name of the survey module.'
                  example: Feedback
                content:
                  type: The
                  description: 'content of the survey module.'
                  example: 'A brief Description'
                trackCompletion:
                  type: boolean
                  description: 'Whether the module is being tracked(whether its finished or not) in course player.'
                  example: false
                estimatedCompletion:
                  type: integer
                  description: 'The estimated time in minutes to complete the module.'
                  example: 60
                estimationCompletedUnit:
                  type: string
                  description: 'The unit of estimated completion time.'
                  example: minutes
                submitButtonText:
                  type: string
                  description: 'The text for the submit button.'
                  example: 'Submit Form'
                submitOption:
                  type: string
                  description: 'The option on how to submit the form.'
                  example: send_email
                fields:
                  type: array
                  description: 'Array of form fields.'
                  example:
                    - quos
                  items:
                    type: string
      security: []
    get:
      summary: 'Retrieves the details of the specified survey module.'
      operationId: retrievesTheDetailsOfTheSpecifiedSurveyModule
      description: 'Retrieves the details of the specified survey module. Helps in fetching survey module using its ID. (See Parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: Feedback
                  slug: feedback
                  content: 'A brief Description'
                  redirect: null
                  trackCompletion: false
                  submitButtonText: 'Submit Survey'
                  submitOption: save_to_db
                  fields:
                    -
                      id: 1
                      type: text
                      label: 'How you left'
                      defaultValue: ''
                      isRequired: false
                      optionLabel: []
                    -
                      id: 2
                      type: rating
                      label: 'How you rate us'
                      defaultValue: ''
                      isRequired: false
                      optionLabel: []
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: Feedback
                  slug:
                    type: string
                    example: feedback
                  content:
                    type: string
                    example: 'A brief Description'
                  redirect:
                    type: string
                    example: null
                  trackCompletion:
                    type: boolean
                    example: false
                  submitButtonText:
                    type: string
                    example: 'Submit Survey'
                  submitOption:
                    type: string
                    example: save_to_db
                  fields:
                    type: array
                    example:
                      -
                        id: 1
                        type: text
                        label: 'How you left'
                        defaultValue: ''
                        isRequired: false
                        optionLabel: []
                      -
                        id: 2
                        type: rating
                        label: 'How you rate us'
                        defaultValue: ''
                        isRequired: false
                        optionLabel: []
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        type:
                          type: string
                          example: text
                        label:
                          type: string
                          example: 'How you left'
                        defaultValue:
                          type: string
                          example: ''
                        isRequired:
                          type: boolean
                          example: false
                        optionLabel:
                          type: array
                          example: []
      tags:
        - 'Survey Modules'
      security: []
  /api/module/survey/details:
    get:
      summary: 'Get Survey Module Details'
      operationId: getSurveyModuleDetails
      description: "Retrieves the details of a survey module including its name, slug, content, course information,\ntrack completion status, launch checks, and form field data for a specific course registration and module."
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: '{"name": "Survey Module", "slug": "survey-module", "content": "Detailed content here", "courseName": "Course 1", "courseSlug": "http://localhost:8000/courses/1/launch", "trackCompletion": true, "min_time_spent": 90, "otherModules": [], "launchCheck": {...}, "errors": [], "course_id": 1, "prevSlug": "previous-module", "nextSlug": "next-module", "status": "In Progress", "timeSpent": 0, "statusRowId": 1, "form_id": 3, "has_form_fields": true, "form_fields": [], "timeToBeSpent": 1}'
      tags:
        - 'Survey Modules'
      security: []
    parameters:
      -
        in: path
        name: registrationId
        description: 'The ID of the course registration.'
        example: '1'
        required: true
        schema:
          type: string
      -
        in: path
        name: moduleId
        description: 'The ID of the survey module.'
        example: '2'
        required: true
        schema:
          type: string
      -
        in: path
        name: portalId
        description: 'Optional parameter. The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
        required: true
        schema:
          type: integer
        examples:
          omitted:
            summary: 'When the value is omitted'
            value: ''
          present:
            summary: 'When the value is present'
            value: 5
  /api/module/survey/markComplete:
    put:
      summary: 'Mark Complete Survey Module'
      operationId: markCompleteSurveyModule
      description: "Updates the status of the survey module to completed.\nChanges the completion percentage to 100% and marks completed the survey module."
      parameters:
        -
          in: query
          name: statusRowId
          description: 'ID of the ModuleStatus Row belongs to current survey module.'
          example: '4'
          required: true
          schema:
            type: string
            description: 'ID of the ModuleStatus Row belongs to current survey module.'
            example: '4'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module Completed Successfully'
                properties:
                  message:
                    type: string
                    example: 'Module Completed Successfully'
      tags:
        - 'Survey Modules'
      security: []
  /api/module/survey/student-details:
    get:
      summary: 'Get Student Response'
      operationId: getStudentResponse
      description: "Returns all the survey module user response of the course in a tabular list format in paginated mode.\nYou can apply filter using search_param via name and scormType(version)."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  question:
                    - 'How you felt'
                    - 'How you rate us'
                  answer:
                    - 'Awesome course it was'
                    - '5'
                properties:
                  question:
                    type: array
                    example:
                      - 'How you felt'
                      - 'How you rate us'
                    items:
                      type: string
                  answer:
                    type: array
                    example:
                      - 'Awesome course it was'
                      - '5'
                    items:
                      type: string
      tags:
        - 'Survey Modules'
      security: []
    parameters:
      -
        in: path
        name: statusRowId
        description: 'ID of the ModuleStatus Row belongs to current text module.'
        example: totam
        required: true
        schema:
          type: string
  /api/module/survey/course-details:
    get:
      summary: 'Survey User Response'
      operationId: surveyUserResponse
      description: "Retrieves all the survey modules user response of the course in a tabular list format in paginated mode.\nYou can apply filter using search_param via name and scormType(version)."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'For searching items based on field names.'
          example: '{"userName":""}'
          required: false
          schema:
            type: string
            description: 'For searching items based on field names.'
            example: '{"userName":""}'
        -
          in: query
          name: course_id
          description: 'Course ID for which you want to get user response.'
          example: '4'
          required: true
          schema:
            type: string
            description: 'Course ID for which you want to get user response.'
            example: '4'
        -
          in: query
          name: portalId
          description: 'Portal ID for which you want to get user response.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Portal ID for which you want to get user response.'
            example: '1'
        -
          in: query
          name: type
          description: 'Type of the response.'
          example: export
          required: true
          schema:
            type: string
            description: 'Type of the response.'
            example: export
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  headers:
                    - student_id
                    - student_name
                    - student_email
                    - first_name
                    - last_name
                    - email
                    - submitted_on
                  form_data:
                    -
                      student_id: 1
                      student_name: 'John Doe'
                      student_email: john.doe@example.com
                      'Question 1': 'Answer 1'
                      'Question 2': 'Answer 2'
                      'Submitted On': 10-Aug-2020
                  form_id:
                    - 1
                    - 2
                  course_name: 'My Course Name'
                properties:
                  headers:
                    type: array
                    example:
                      - student_id
                      - student_name
                      - student_email
                      - first_name
                      - last_name
                      - email
                      - submitted_on
                    items:
                      type: string
                  form_data:
                    type: array
                    example:
                      -
                        student_id: 1
                        student_name: 'John Doe'
                        student_email: john.doe@example.com
                        'Question 1': 'Answer 1'
                        'Question 2': 'Answer 2'
                        'Submitted On': 10-Aug-2020
                    items:
                      type: object
                      properties:
                        student_id:
                          type: integer
                          example: 1
                        student_name:
                          type: string
                          example: 'John Doe'
                        student_email:
                          type: string
                          example: john.doe@example.com
                        'Question 1':
                          type: string
                          example: 'Answer 1'
                        'Question 2':
                          type: string
                          example: 'Answer 2'
                        'Submitted On':
                          type: string
                          example: 10-Aug-2020
                  form_id:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  course_name:
                    type: string
                    example: 'My Course Name'
      tags:
        - 'Survey Modules'
      security: []
  /api/module/survey/course-details-count:
    get:
      summary: 'Retrieves the count of the maximum number of the form submissions in a single form in a specified course.'
      operationId: retrievesTheCountOfTheMaximumNumberOfTheFormSubmissionsInASingleFormInASpecifiedCourse
      description: 'Used to estimiate the number of seperate requests are needed to fetch all responses in chunks. (See response)'
      parameters:
        -
          in: query
          name: course_id
          description: 'Course ID for which you want to get user response.'
          example: '4'
          required: true
          schema:
            type: string
            description: 'Course ID for which you want to get user response.'
            example: '4'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  max_form_data_count: 2
                properties:
                  max_form_data_count:
                    type: integer
                    example: 2
      tags:
        - 'Survey Modules'
      security: []
  /api/module/survey/survey-count:
    get:
      summary: 'Survey Report'
      operationId: surveyReport
      description: "Retrieves a paginated list of courses along with their associated survey modules.\nThe result can be filtered by course name or ID, and restricted to specific portals.\nThe function also supports ordering of the result set based on specified columns."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of items you want per page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of items you want per page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'The current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'The current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'JSON object for ordering items based on columns.'
          example: '{"colName":"name", "direction": "asc"}'
          required: false
          schema:
            type: string
            description: 'JSON object for ordering items based on columns.'
            example: '{"colName":"name", "direction": "asc"}'
        -
          in: query
          name: search_param
          description: 'JSON object for searching courses by name or ID.'
          example: '{"courseName":"Math", "courseId":1}'
          required: false
          schema:
            type: string
            description: 'JSON object for searching courses by name or ID.'
            example: '{"courseName":"Math", "courseId":1}'
        -
          in: query
          name: portalId
          description: 'Optional portal ID to restrict results to a specific portal and its sub-portals.'
          example: '2'
          required: false
          schema:
            type: string
            description: 'Optional portal ID to restrict results to a specific portal and its sub-portals.'
            example: '2'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 100
                  recordsFiltered: 50
                  records:
                    -
                      id: 1
                      name: 'Course Name'
                      survey:
                        -
                          id: 1
                          name: 'Survey Name'
                          formId: 123
                          count: 10
                      count: 10
                properties:
                  recordsTotal:
                    type: integer
                    example: 100
                  recordsFiltered:
                    type: integer
                    example: 50
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: 'Course Name'
                        survey:
                          -
                            id: 1
                            name: 'Survey Name'
                            formId: 123
                            count: 10
                        count: 10
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: 'Course Name'
                        survey:
                          type: array
                          example:
                            -
                              id: 1
                              name: 'Survey Name'
                              formId: 123
                              count: 10
                          items:
                            type: object
                            properties:
                              id:
                                type: integer
                                example: 1
                              name:
                                type: string
                                example: 'Survey Name'
                              formId:
                                type: integer
                                example: 123
                              count:
                                type: integer
                                example: 10
                        count:
                          type: integer
                          example: 10
      tags:
        - 'Survey Modules'
      security: []
  /api/survey/survey-check:
    get:
      summary: 'Get All Users’ Survey Responses by Course and Module'
      operationId: getAllUsersSurveyResponsesByCourseAndModule
      description: "Retrieves paginated survey/form responses submitted by users for a specific module within a course.\nSupports search filtering, sub-portal filtering, and returns processed answers per question."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of records per page.'
          example: 10
          required: true
          schema:
            type: integer
            description: 'The number of records per page.'
            example: 10
        -
          in: query
          name: page_number
          description: 'The current page number.'
          example: 1
          required: true
          schema:
            type: integer
            description: 'The current page number.'
            example: 1
        -
          in: query
          name: course_id
          description: 'The ID of the course.'
          example: 42
          required: true
          schema:
            type: integer
            description: 'The ID of the course.'
            example: 42
        -
          in: query
          name: module_id
          description: 'The ID of the module.'
          example: 108
          required: true
          schema:
            type: integer
            description: 'The ID of the module.'
            example: 108
        -
          in: query
          name: portalId
          description: 'optional The ID of the portal to filter user responses by portal and sub-portals.'
          example: 3
          required: false
          schema:
            type: integer
            description: 'optional The ID of the portal to filter user responses by portal and sub-portals.'
            example: 3
        -
          in: query
          name: search_param
          description: 'optional JSON-encoded object to filter by user name or email.'
          example: '{"userName":"John"}'
          required: false
          schema:
            type: string
            description: 'optional JSON-encoded object to filter by user name or email.'
            example: '{"userName":"John"}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  form_data:
                    -
                      submissions:
                        -
                          question: 'How would you rate this course?'
                          answer: '5'
                        -
                          question: 'Any comments?'
                          answer: 'Very helpful!'
                      name: 'John Doe'
                      email: john@example.com
                  courseName: 'Introduction to Programming'
                  moduleName: 'Module 1: Basics'
                  form_data_count: 1
                  recordsTotal: 10
                  recordsFiltered: 1
                properties:
                  form_data:
                    type: array
                    example:
                      -
                        submissions:
                          -
                            question: 'How would you rate this course?'
                            answer: '5'
                          -
                            question: 'Any comments?'
                            answer: 'Very helpful!'
                        name: 'John Doe'
                        email: john@example.com
                    items:
                      type: object
                      properties:
                        submissions:
                          type: array
                          example:
                            -
                              question: 'How would you rate this course?'
                              answer: '5'
                            -
                              question: 'Any comments?'
                              answer: 'Very helpful!'
                          items:
                            type: object
                            properties:
                              question:
                                type: string
                                example: 'How would you rate this course?'
                              answer:
                                type: string
                                example: '5'
                        name:
                          type: string
                          example: 'John Doe'
                        email:
                          type: string
                          example: john@example.com
                  courseName:
                    type: string
                    example: 'Introduction to Programming'
                  moduleName:
                    type: string
                    example: 'Module 1: Basics'
                  form_data_count:
                    type: integer
                    example: 1
                  recordsTotal:
                    type: integer
                    example: 10
                  recordsFiltered:
                    type: integer
                    example: 1
      tags:
        - 'Survey Modules'
      security: []
  /api/module/survey/save-response:
    post:
      summary: 'Saves the survey form submission data'
      operationId: savesTheSurveyFormSubmissionData
      description: 'Saves the survey form submission data and returns the id of the saved form submission'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Form saved successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Form saved successfully'
      tags:
        - 'Survey Modules'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                content:
                  type: string
                  description: 'Content of the text module.'
                  example: 'A brief Description'
                form_id:
                  type: integer
                  description: 'Form ID for which you want to save the form submission.'
                  example: 1
                name:
                  type: string
                  description: 'Name of the form.'
                  example: Feedback
                form_fields:
                  type: array
                  description: 'Form fields inside the Survey form(like radio, dropdown, rating, text, textarea, etc).'
                  example:
                    -
                      type: text
                      label: 'How you left'
                      submitted_value: ''
                      options_label: []
                      options_value: []
                    -
                      type: rating
                      label: 'How you rate us'
                      submitted_value: 5
                      options_label: []
                      options_value: []
                  items:
                    type: string
                statusRowId:
                  type: required
                  description: 'ID of the Module status of the current survey module.'
                  example: '7'
              required:
                - content
                - form_id
                - name
                - form_fields
      security: []
  /api/modules/text:
    get:
      summary: 'Text Modules Tabular List'
      operationId: textModulesTabularList
      description: "Returns all the text modules in a tabular list format in paginated mode.\nYou can apply filter using search_param via moduleTypes(module type), associatedCourse(modules used in course) and moduleName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"moduleTypes": ["text"],associatedCourse":"","moduleName":""}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"moduleTypes": ["text"],associatedCourse":"","moduleName":""}'
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: '{"recordsTotal":1,"recordsFiltered":1,"records":[{"id":1,"name":"test","slug":"test","type":"text","icon":"<i class=\"el-icon-document\"><\/i>","author":"Aom Staff","created_at":"Aug 03, 2020 09:56 AM","course_count":1}]}}'
      tags:
        - 'Text Modules'
      security: []
    post:
      summary: 'Create Text Module'
      operationId: createTextModule
      description: 'Creates a new text module. (See parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - 'Text Modules'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: required
                  description: 'Name of the text module.'
                  example: 'Getting Started'
                content:
                  type: string
                  description: 'Content for the text modules that students will see.'
                  example: '<p>This is the updated short content here</p>'
                trackCompletion:
                  type: boolean
                  description: 'If true, the module is being tracked(whether its finished or not) in course player.'
                  example: true
                estimatedCompletion:
                  type: string
                  description: 'Estimated time to complete in course player.'
                  example: '00:30:00'
                estimationCompletedUnit:
                  type: string
                  description: 'Unit of estimated time to complete in course player.'
                  example: minutes
                categories:
                  type: array
                  description: 'Categories to be added to the module.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - content
                - trackCompletion
      security: []
  '/api/modules/text/{id}':
    get:
      summary: 'Get Text Module'
      operationId: getTextModule
      description: "Retrieves the details of the specified text module. Helps in fetching text module using module ID. (See Parameters)\nReturns : id, name, slug, content, trackCompletion, estimatedCompletion, estimationCompletedUnit and categories of the text module created."
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 6
                  name: 'Getting Started'
                  slug: getting-started
                  content: ' '
                  trackCompletion: false
                  estimatedCompletion: null
                  estimationCompletedUnit: null
                  categories:
                    - 1
                    - 2
                    - 3
                  courses:
                    -
                      course_id: 1
                      course_name: 'Course Name'
                properties:
                  id:
                    type: integer
                    example: 6
                  name:
                    type: string
                    example: 'Getting Started'
                  slug:
                    type: string
                    example: getting-started
                  content:
                    type: string
                    example: ' '
                  trackCompletion:
                    type: boolean
                    example: false
                  estimatedCompletion:
                    type: string
                    example: null
                  estimationCompletedUnit:
                    type: string
                    example: null
                  categories:
                    type: array
                    example:
                      - 1
                      - 2
                      - 3
                    items:
                      type: integer
                  courses:
                    type: array
                    example:
                      -
                        course_id: 1
                        course_name: 'Course Name'
                    items:
                      type: object
                      properties:
                        course_id:
                          type: integer
                          example: 1
                        course_name:
                          type: string
                          example: 'Course Name'
      tags:
        - 'Text Modules'
      security: []
    put:
      summary: 'Update Text Module'
      operationId: updateTextModule
      description: "Updates the details of the specified text module. (See parameters)\nText modules can be used in the course as course content/lesson.\n\nReturns : Successfull message"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Module updated successfully'
      tags:
        - 'Text Modules'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: required
                  description: 'Name of the text module.'
                  example: My-text-lesson
                content:
                  type: string
                  description: 'Content for the text modules that students will see.'
                  example: '<p>This is the updated short content here</p>'
                trackCompletion:
                  type: boolean
                  description: 'If true, the module is being tracked(whether its finished or not) in course player.'
                  example: true
                estimatedCompletion:
                  type: string
                  description: 'Estimated time to complete in course player.'
                  example: '00:30:00'
                estimationCompletedUnit:
                  type: string
                  description: 'Unit of estimated time to complete in course player.'
                  example: minutes
                categories:
                  type: array
                  description: 'Categories to be added to the module.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
              required:
                - content
                - trackCompletion
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'ID of the text module.'
        example: '6'
        required: true
        schema:
          type: string
  /api/module/text/details:
    get:
      summary: 'Get Text Module Details'
      operationId: getTextModuleDetails
      description: 'To get the details of a text module, you need to use this request. (See parameters)'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: '{"name": "First Text", "slug": "first-text", "content": "A brief description", "courseName": "First Course", "courseSlug": "http://localhost:8000/courses/1/launch", "url": "http://localhost:8000/courses/1/modules/2/launch", "totalPoints": 20, "shouldBeEvaluated": true, "min_time_spent": 90, "otherModules": []], "launchCheck": {...}, "prevSlug": "first-video", "nextSlug": "second-video", "currentUserId": 1, "currentStudentAvatar": "http://localhost:8000/storage/avatars/1.png", "currentUserName": "John Doe", "status": "In Progress", "statusRowId": 1, "timeSpent": 0, "course_newly_completed": false, "timeToBeSpent": 1, "instructorResponse": null}'
      tags:
        - 'Text Modules'
      security: []
    parameters:
      -
        in: path
        name: registrationId
        description: 'ID of the course registration.'
        example: '1'
        required: true
        schema:
          type: string
      -
        in: path
        name: moduleId
        description: 'ID of the text module.'
        example: '2'
        required: true
        schema:
          type: string
      -
        in: path
        name: portalId
        description: 'Optional parameter. The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
        required: true
        schema:
          type: integer
        examples:
          omitted:
            summary: 'When the value is omitted'
            value: ''
          present:
            summary: 'When the value is present'
            value: 5
  /api/module/text/markComplete:
    put:
      summary: 'Mark Complete Text Module'
      operationId: markCompleteTextModule
      description: "Updates the status of the text module to completed.\nChanges the completion percentage to 100% and marks completed the text module."
      parameters:
        -
          in: query
          name: statusRowId
          description: 'ID of the ModuleStatus Row belongs to current text module.'
          example: '4'
          required: true
          schema:
            type: string
            description: 'ID of the ModuleStatus Row belongs to current text module.'
            example: '4'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  is_success: true
                  message: 'Module Completed Successfully'
                  course_newly_completed: false
                properties:
                  is_success:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Module Completed Successfully'
                  course_newly_completed:
                    type: boolean
                    example: false
      tags:
        - 'Text Modules'
      security: []
  /api/module/text/content-details:
    get:
      summary: 'Retrieve Detailed Text Module Info for Membership content'
      operationId: retrieveDetailedTextModuleInfoForMembershipContent
      description: "Retrieves details of text module in depth for the same membership the current text module is attached to.\nReturns related fields value. (See Response)"
      parameters:
        -
          in: query
          name: moduleId
          description: 'ID of the text module.'
          example: '9'
          required: true
          schema:
            type: string
            description: 'ID of the text module.'
            example: '9'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Getting Started'
                  slug: getting-started
                  content: ' '
                  trackCompletion: true
                  timeSpent: null
                properties:
                  name:
                    type: string
                    example: 'Getting Started'
                  slug:
                    type: string
                    example: getting-started
                  content:
                    type: string
                    example: ' '
                  trackCompletion:
                    type: boolean
                    example: true
                  timeSpent:
                    type: string
                    example: null
      tags:
        - 'Text Modules'
      security: []
  /api/modules/video:
    get:
      summary: 'Video Modules Tabular List'
      operationId: videoModulesTabularList
      description: "Returns all the video modules in a tabular list format in paginated mode.\nYou can apply filter using search_param via associatedCourse(modules used in course) and moduleName."
      parameters:
        -
          in: query
          name: page_size
          description: 'The number of the items you want for a page.'
          example: '50'
          required: true
          schema:
            type: string
            description: 'The number of the items you want for a page.'
            example: '50'
        -
          in: query
          name: page_number
          description: 'Current page number in pagination.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'Current page number in pagination.'
            example: '1'
        -
          in: query
          name: order_by
          description: 'For ordering items based on columns provided in JSON format.'
          example: '{"colName":"created_at", "direction": "desc"}'
          required: false
          schema:
            type: string
            description: 'For ordering items based on columns provided in JSON format.'
            example: '{"colName":"created_at", "direction": "desc"}'
        -
          in: query
          name: search_param
          description: 'for searching items based on field names.'
          example: '{"associatedCourse":"","moduleName":""}'
          required: false
          schema:
            type: string
            description: 'for searching items based on field names.'
            example: '{"associatedCourse":"","moduleName":""}'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recordsTotal: 1
                  recordsFiltered: 1
                  records:
                    -
                      id: 1
                      name: test
                      slug: test
                      type: video
                      icon: '<i class="el-icon-document"></i>'
                      author: 'Aom Staff'
                      created_at: 'Aug 03, 2020 09:56 AM'
                      course_count: 1
                properties:
                  recordsTotal:
                    type: integer
                    example: 1
                  recordsFiltered:
                    type: integer
                    example: 1
                  records:
                    type: array
                    example:
                      -
                        id: 1
                        name: test
                        slug: test
                        type: video
                        icon: '<i class="el-icon-document"></i>'
                        author: 'Aom Staff'
                        created_at: 'Aug 03, 2020 09:56 AM'
                        course_count: 1
                    items:
                      type: object
                      properties:
                        id:
                          type: integer
                          example: 1
                        name:
                          type: string
                          example: test
                        slug:
                          type: string
                          example: test
                        type:
                          type: string
                          example: video
                        icon:
                          type: string
                          example: '<i class="el-icon-document"></i>'
                        author:
                          type: string
                          example: 'Aom Staff'
                        created_at:
                          type: string
                          example: 'Aug 03, 2020 09:56 AM'
                        course_count:
                          type: integer
                          example: 1
      tags:
        - Videos
      security: []
    post:
      summary: 'Create Video Module'
      operationId: createVideoModule
      description: "Creates a new video module with the provided details. (See parameters)\nVideo modules can be used in the course as course content/lesson.\n\nReturns : id of the video module created and success message"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  message: 'Module saved successfully'
                properties:
                  id:
                    type: integer
                    example: 1
                  message:
                    type: string
                    example: 'Module saved successfully'
      tags:
        - Videos
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 'Name of the video module.'
                  example: My-video-lesson
                content:
                  type: string
                  description: 'Content for the video modules that students will see.'
                  example: 'Brief Description'
                url:
                  type: string
                  description: 'Url path for the video module.'
                  example: 'https://player.vimeo.com/video/382947752'
                provider:
                  type: string
                  description: 'Provider of the video. Options: vimeo, in-house, youtube.'
                  example: vimeo
                coverUrl:
                  type: string
                  description: 'Cover url path for the video module.'
                  example: 'https://picsum.photos/200/300'
                trackCompletion:
                  type: boolean
                  description: 'Whether the module is tracked for completion in the course player.'
                  example: true
                estimatedCompletion:
                  type: string
                  description: 'Estimated time to complete in course player.'
                  example: '00:30:00'
                estimationCompletedUnit:
                  type: string
                  description: 'Unit of estimated time to complete in course player.'
                  example: minutes
                disableForwardSeek:
                  type: boolean
                  description: 'If true, students cannot skip forward in the video.'
                  example: true
                categories:
                  type: array
                  description: 'Categories to associate with the module.'
                  example:
                    - 1
                    - 2
                    - 3
                  items:
                    type: string
                subtitleType:
                  type: string
                  description: 'Type of subtitle in the video. Options: upload, nocaption.'
                  example: upload
                interactions:
                  type: array
                  description: 'Interactions to add in the video.'
                  example:
                    -
                      type: quiz
                      time: '00:05:00'
                  items:
                    type: string
                subtitles:
                  type: array
                  description: "Subtitles to add if subtitleType is 'upload'."
                  example:
                    -
                      language: en
                      subtitleContent: 'Subtitle text'
                  items:
                    type: string
              required:
                - name
                - url
                - provider
      security: []
  '/api/modules/video/{id}':
    get:
      summary: 'Video Module Details'
      operationId: videoModuleDetails
      description: 'Returns a video module details given its Id. This API is used by the course player to fetch the video module details while playing the course.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  id: 1
                  name: test
                  slug: test
                  content: 'This is a test video module.'
                  provider: vimeo
                  url: 'https://vimeo.com/123456789'
                  coverUrl: 'https://picsum.photos/200/300'
                  disableForwardSeek: false
                  trackCompletion: false
                  estimatedCompletion: null
                  estimationCompletedUnit: null
                  subtitleType: ''
                  subtitleFilePath:
                    -
                      language: en
                      filePath: /storage/vtt/en_1.vtt
                  categories:
                    - 1
                    - 2
                  courses:
                    -
                      course_id: 1
                      course_name: 'My Course'
                  subtitleDetails:
                    -
                      subtitleContent: 'This is a test subtitle.'
                      language: en
                properties:
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: test
                  slug:
                    type: string
                    example: test
                  content:
                    type: string
                    example: 'This is a test video module.'
                  provider:
                    type: string
                    example: vimeo
                  url:
                    type: string
                    example: 'https://vimeo.com/123456789'
                  coverUrl:
                    type: string
                    example: 'https://picsum.photos/200/300'
                  disableForwardSeek:
                    type: boolean
                    example: false
                  trackCompletion:
                    type: boolean
                    example: false
                  estimatedCompletion:
                    type: string
                    example: null
                  estimationCompletedUnit:
                    type: string
                    example: null
                  subtitleType:
                    type: string
                    example: ''
                  subtitleFilePath:
                    type: array
                    example:
                      -
                        language: en
                        filePath: /storage/vtt/en_1.vtt
                    items:
                      type: object
                      properties:
                        language:
                          type: string
                          example: en
                        filePath:
                          type: string
                          example: /storage/vtt/en_1.vtt
                  categories:
                    type: array
                    example:
                      - 1
                      - 2
                    items:
                      type: integer
                  courses:
                    type: array
                    example:
                      -
                        course_id: 1
                        course_name: 'My Course'
                    items:
                      type: object
                      properties:
                        course_id:
                          type: integer
                          example: 1
                        course_name:
                          type: string
                          example: 'My Course'
                  subtitleDetails:
                    type: array
                    example:
                      -
                        subtitleContent: 'This is a test subtitle.'
                        language: en
                    items:
                      type: object
                      properties:
                        subtitleContent:
                          type: string
                          example: 'This is a test subtitle.'
                        language:
                          type: string
                          example: en
      tags:
        - Videos
      security: []
    put:
      summary: 'Update the specified video module in storage.'
      operationId: updateTheSpecifiedVideoModuleInStorage
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module updated successfully'
                properties:
                  message:
                    type: string
                    example: 'Module updated successfully'
      tags:
        - Videos
      security: []
    parameters:
      -
        in: path
        name: id
        description: 'The id of the video module.'
        example: '3'
        required: true
        schema:
          type: string
  /api/module/video/details:
    get:
      summary: 'Video Module Details'
      operationId: videoModuleDetails
      description: 'Returns a video module details given its Id. This API is used by the course player to fetch the video module details while playing the course.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: test
                  slug: test
                  content: 'This is a test video module.'
                  courseName: 'My Course'
                  courseSlug: my-course
                  min_time_spent: 5
                  otherModules:
                    -
                      module_id: 1
                      module_name: 'Module 1'
                      module_slug: module-1
                      display_order: 1
                    -
                      module_id: 2
                      module_name: 'Module 2'
                      module_slug: module-2
                      display_order: 2
                  subtitleType: ''
                  subtitleFilePath:
                    -
                      language: en
                      filePath: /storage/vtt/en_1.vtt
                  launchCheck:
                    canbeLaunched: true
                    errDesc: ''
                  prevSlug: module-1
                  nextSlug: module-2
                  provider: vimeo
                  coverUrl: 'https://picsum.photos/200/300'
                  url: 'https://vimeo.com/123456789'
                  disableForwardSeek: false
                  trackCompletion: false
                  interactions: []
                  courseStatus: 'In Progress'
                  status: 'In Progress'
                  statusRowId: 1
                  timeSpent: 0
                  lastWatchedTime: 0
                  isReady: true
                  course_newly_completed: false
                properties:
                  name:
                    type: string
                    example: test
                  slug:
                    type: string
                    example: test
                  content:
                    type: string
                    example: 'This is a test video module.'
                  courseName:
                    type: string
                    example: 'My Course'
                  courseSlug:
                    type: string
                    example: my-course
                  min_time_spent:
                    type: integer
                    example: 5
                  otherModules:
                    type: array
                    example:
                      -
                        module_id: 1
                        module_name: 'Module 1'
                        module_slug: module-1
                        display_order: 1
                      -
                        module_id: 2
                        module_name: 'Module 2'
                        module_slug: module-2
                        display_order: 2
                    items:
                      type: object
                      properties:
                        module_id:
                          type: integer
                          example: 1
                        module_name:
                          type: string
                          example: 'Module 1'
                        module_slug:
                          type: string
                          example: module-1
                        display_order:
                          type: integer
                          example: 1
                  subtitleType:
                    type: string
                    example: ''
                  subtitleFilePath:
                    type: array
                    example:
                      -
                        language: en
                        filePath: /storage/vtt/en_1.vtt
                    items:
                      type: object
                      properties:
                        language:
                          type: string
                          example: en
                        filePath:
                          type: string
                          example: /storage/vtt/en_1.vtt
                  launchCheck:
                    type: object
                    properties:
                      canbeLaunched:
                        type: boolean
                        example: true
                      errDesc:
                        type: string
                        example: ''
                  prevSlug:
                    type: string
                    example: module-1
                  nextSlug:
                    type: string
                    example: module-2
                  provider:
                    type: string
                    example: vimeo
                  coverUrl:
                    type: string
                    example: 'https://picsum.photos/200/300'
                  url:
                    type: string
                    example: 'https://vimeo.com/123456789'
                  disableForwardSeek:
                    type: boolean
                    example: false
                  trackCompletion:
                    type: boolean
                    example: false
                  interactions:
                    type: array
                    example: []
                  courseStatus:
                    type: string
                    example: 'In Progress'
                  status:
                    type: string
                    example: 'In Progress'
                  statusRowId:
                    type: integer
                    example: 1
                  timeSpent:
                    type: integer
                    example: 0
                  lastWatchedTime:
                    type: integer
                    example: 0
                  isReady:
                    type: boolean
                    example: true
                  course_newly_completed:
                    type: boolean
                    example: false
      tags:
        - Videos
      security: []
    parameters:
      -
        in: path
        name: registrationId
        description: 'The id of the registration.'
        example: '1'
        required: true
        schema:
          type: string
      -
        in: path
        name: moduleId
        description: 'The id of the video module.'
        example: '3'
        required: true
        schema:
          type: string
      -
        in: path
        name: portalId
        description: 'The id of the portal.'
        example: '1'
        required: true
        schema:
          type: string
  /api/module/video/markComplete:
    put:
      summary: 'Mark Complete Video Module'
      operationId: markCompleteVideoModule
      description: "Updates the status of the video module to completed.\nChanges the completion percentage to 100% and marks completed the video module."
      parameters:
        -
          in: query
          name: statusRowId
          description: 'ID of the ModuleStatus Row belongs to current video module.'
          example: '4'
          required: true
          schema:
            type: string
            description: 'ID of the ModuleStatus Row belongs to current video module.'
            example: '4'
        -
          in: query
          name: videoDuration
          description: 'The duration of the video in seconds.'
          example: '90'
          required: true
          schema:
            type: string
            description: 'The duration of the video in seconds.'
            example: '90'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: 5
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  status: true
                  message: 'Module completed successfully'
                  course_newly_completed: false
                properties:
                  status:
                    type: boolean
                    example: true
                  message:
                    type: string
                    example: 'Module completed successfully'
                  course_newly_completed:
                    type: boolean
                    example: false
      tags:
        - Videos
      security: []
  /api/module/video/content-details:
    get:
      summary: 'Retrieve Detailed Video Module Info for Membership content'
      operationId: retrieveDetailedVideoModuleInfoForMembershipContent
      description: "This function retrieves details of a video module, including its name, slug, content, provider, cover URL, and URL.\nIt checks if the video is ready to be viewed, updates the time spent and last watched time, and indicates whether\nthe video is part of membership content. If the video is not ready, an error message is included in the response."
      parameters:
        -
          in: query
          name: moduleId
          description: 'ID of the video module.'
          example: '9'
          required: true
          schema:
            type: string
            description: 'ID of the video module.'
            example: '9'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  name: 'Module Name'
                  slug: module-slug
                  content: 'Content of the module'
                  provider: in-house
                  coverUrl: 'https://example.com/cover.jpg'
                  url: 'https://example.com/video.mp4'
                  disableForwardSeek: false
                  trackCompletion: true
                  timeSpent: 120
                  lastWatchedTime: 30
                  isPartOfMembershipContent: true
                  isReady: true
                properties:
                  name:
                    type: string
                    example: 'Module Name'
                  slug:
                    type: string
                    example: module-slug
                  content:
                    type: string
                    example: 'Content of the module'
                  provider:
                    type: string
                    example: in-house
                  coverUrl:
                    type: string
                    example: 'https://example.com/cover.jpg'
                  url:
                    type: string
                    example: 'https://example.com/video.mp4'
                  disableForwardSeek:
                    type: boolean
                    example: false
                  trackCompletion:
                    type: boolean
                    example: true
                  timeSpent:
                    type: integer
                    example: 120
                  lastWatchedTime:
                    type: integer
                    example: 30
                  isPartOfMembershipContent:
                    type: boolean
                    example: true
                  isReady:
                    type: boolean
                    example: true
      tags:
        - Videos
      security: []
  /api/webinar/deleteWebinar:
    post:
      summary: 'Delete a webinar module'
      operationId: deleteAWebinarModule
      description: "Deletes a webinar module and it's associated schedules."
      parameters:
        -
          in: query
          name: webinarId
          description: 'ID of the webinar module.'
          example: '1'
          required: true
          schema:
            type: string
            description: 'ID of the webinar module.'
            example: '1'
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example: {  }
                properties: {  }
      tags:
        - 'Webinar Management API'
      security: []
  /api/webinar/recurrence-webinar:
    post:
      summary: 'Create a new webinar module with recurrence.'
      operationId: createANewWebinarModuleWithRecurrence
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  recurrenceWebinar:
                    -
                      startDate: '2020-01-01'
                      endDate: '2020-01-01'
                      startTime: '10:00:00'
                      endTime: '11:00:00'
                      location: 1
                      instructor: 1
                      showEdit: false
                      serviceProvider: zoom
                      enableCloudRecording: true
                      allowDownload: true
                      meetingUrl: 'https://zoom.us/j/1234567890'
                      enableAutoAttendance: true
                      attendanceThreshold: 80
                  message: 'Webinar created successfully'
                  status: success
                properties:
                  recurrenceWebinar:
                    type: array
                    example:
                      -
                        startDate: '2020-01-01'
                        endDate: '2020-01-01'
                        startTime: '10:00:00'
                        endTime: '11:00:00'
                        location: 1
                        instructor: 1
                        showEdit: false
                        serviceProvider: zoom
                        enableCloudRecording: true
                        allowDownload: true
                        meetingUrl: 'https://zoom.us/j/1234567890'
                        enableAutoAttendance: true
                        attendanceThreshold: 80
                    items:
                      type: object
                      properties:
                        startDate:
                          type: string
                          example: '2020-01-01'
                        endDate:
                          type: string
                          example: '2020-01-01'
                        startTime:
                          type: string
                          example: '10:00:00'
                        endTime:
                          type: string
                          example: '11:00:00'
                        location:
                          type: integer
                          example: 1
                        instructor:
                          type: integer
                          example: 1
                        showEdit:
                          type: boolean
                          example: false
                        serviceProvider:
                          type: string
                          example: zoom
                        enableCloudRecording:
                          type: boolean
                          example: true
                        allowDownload:
                          type: boolean
                          example: true
                        meetingUrl:
                          type: string
                          example: 'https://zoom.us/j/1234567890'
                        enableAutoAttendance:
                          type: boolean
                          example: true
                        attendanceThreshold:
                          type: integer
                          example: 80
                  message:
                    type: string
                    example: 'Webinar created successfully'
                  status:
                    type: string
                    example: success
      tags:
        - 'Webinar Management API'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                attendanceThreshold:
                  type: integer
                  description: 'The attendance threshold for the webinar. Must be between 0 and 100.'
                  example: 17
                startDate:
                  type: string
                  description: "The start date of the webinar in the format 'Y-m-d'."
                  example: rerum
                startTime:
                  type: string
                  description: "The start time of the webinar in the format 'H:i:s'."
                  example: veniam
                endTime:
                  type: string
                  description: "The end time of the webinar in the format 'H:i:s'."
                  example: numquam
                location:
                  type: integer
                  description: 'The location id of the webinar.'
                  example: 18
                instructor:
                  type: integer
                  description: 'The instructor id of the webinar.'
                  example: 12
                serviceProvider:
                  type: string
                  description: 'The service provider for the webinar.'
                  example: quibusdam
                enableCloudRecording:
                  type: boolean
                  description: 'Whether to enable cloud recording for the webinar.'
                  example: false
                allowDownload:
                  type: boolean
                  description: 'Whether to allow download of the webinar.'
                  example: false
                meetingUrl:
                  type: string
                  description: 'The meeting url for the webinar.'
                  example: 'http://www.maggio.info/in-repellat-repellendus-vero-praesentium-commodi-dolor'
                enableAutoAttendance:
                  type: boolean
                  description: 'Whether to enable auto attendance for the webinar.'
                  example: false
                enableRecurrence:
                  type: boolean
                  description: 'Whether to enable recurrence for the webinar.'
                  example: false
                frequency:
                  type: string
                  description: 'The frequency of the recurrence.'
                  example: error
                interval:
                  type: integer
                  description: 'The interval of the recurrence.'
                  example: 6
                end:
                  type: string
                  description: "The end date of the recurrence in the format 'Y-m-d'."
                  example: tenetur
                webinarDays:
                  type: integer
                  description: 'The number of days for the recurrence.'
                  example: 13
              required:
                - attendanceThreshold
                - startDate
                - startTime
                - endTime
                - location
                - instructor
                - serviceProvider
                - enableCloudRecording
                - allowDownload
                - meetingUrl
                - enableAutoAttendance
                - enableRecurrence
                - frequency
                - interval
                - end
                - webinarDays
      security: []
  /api/webinar/validate-webinar:
    post:
      summary: 'Validate the webinar request.'
      operationId: validateTheWebinarRequest
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Webinar updated successfully'
                  status: success
                properties:
                  message:
                    type: string
                    example: 'Webinar updated successfully'
                  status:
                    type: string
                    example: success
      tags:
        - 'Webinar Management API'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                attendanceThreshold:
                  type: integer
                  description: 'The attendance threshold for the webinar. Must be between 0 and 100.'
                  example: 8
                startDate:
                  type: string
                  description: "The start date of the webinar in the format 'Y-m-d'."
                  example: architecto
                startTime:
                  type: string
                  description: "The start time of the webinar in the format 'H:i:s'."
                  example: sequi
                endTime:
                  type: string
                  description: "The end time of the webinar in the format 'H:i:s'."
                  example: eveniet
              required:
                - attendanceThreshold
                - startDate
                - startTime
                - endTime
      security: []
  /api/webinar/update-webinar:
    post:
      summary: 'Update a webinar for the given course'
      operationId: updateAWebinarForTheGivenCourse
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Webinar updated successfully'
                  status: success
                properties:
                  message:
                    type: string
                    example: 'Webinar updated successfully'
                  status:
                    type: string
                    example: success
        422:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'The given data was invalid.'
                  errors:
                    message:
                      - 'Start date and time cannot be in the past.'
                properties:
                  message:
                    type: string
                    example: 'The given data was invalid.'
                  errors:
                    type: object
                    properties:
                      message:
                        type: array
                        example:
                          - 'Start date and time cannot be in the past.'
                        items:
                          type: string
      tags:
        - 'Webinar Management API'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                course_id:
                  type: integer
                  description: 'The ID of the course'
                  example: 4
                id:
                  type: integer
                  description: 'The ID of the webinar'
                  example: 20
                webinarList:
                  type: array
                  description: 'The webinar list'
                  example:
                    - similique
                  items:
                    type: string
              required:
                - course_id
                - id
                - webinarList
      security: []
  /api/webinar/add-webinar:
    post:
      summary: 'Create a new webinar in the database.'
      operationId: createANewWebinarInTheDatabase
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Webinar created successfully'
                  status: success
                properties:
                  message:
                    type: string
                    example: 'Webinar created successfully'
                  status:
                    type: string
                    example: success
      tags:
        - 'Webinar Management API'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                course_id:
                  type: integer
                  description: 'The id of the course for which the webinar is being created.'
                  example: 14
                webinarList:
                  type: array
                  description: 'The array of webinars to be created, each containing the following:'
                  example:
                    - error
                  items:
                    type: string
              required:
                - course_id
                - webinarList
      security: []
  /api/webinar/export-attendance:
    get:
      summary: 'Export attendance report for a given webinar'
      operationId: exportAttendanceReportForAGivenWebinar
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  courseName: 'Course Name'
                  startDate: '2020-12-01 10:00:00'
                  endDate: '2020-12-01 11:00:00'
                  recordsTotal: 100
                  totalAttended: 50
                  totalNoShow: 20
                  totalCancelled: 10
                  totalPartiallyAttended: 20
                  records:
                    -
                      firstName: John
                      lastName: Doe
                      email: john.doe@example.com
                      status: Attended
                      attendanceRecordingType: Manual
                      notes: 'Test notes'
                      recordedAt: '2020-12-01 10:00:00'
                properties:
                  courseName:
                    type: string
                    example: 'Course Name'
                  startDate:
                    type: string
                    example: '2020-12-01 10:00:00'
                  endDate:
                    type: string
                    example: '2020-12-01 11:00:00'
                  recordsTotal:
                    type: integer
                    example: 100
                  totalAttended:
                    type: integer
                    example: 50
                  totalNoShow:
                    type: integer
                    example: 20
                  totalCancelled:
                    type: integer
                    example: 10
                  totalPartiallyAttended:
                    type: integer
                    example: 20
                  records:
                    type: array
                    example:
                      -
                        firstName: John
                        lastName: Doe
                        email: john.doe@example.com
                        status: Attended
                        attendanceRecordingType: Manual
                        notes: 'Test notes'
                        recordedAt: '2020-12-01 10:00:00'
                    items:
                      type: object
                      properties:
                        firstName:
                          type: string
                          example: John
                        lastName:
                          type: string
                          example: Doe
                        email:
                          type: string
                          example: john.doe@example.com
                        status:
                          type: string
                          example: Attended
                        attendanceRecordingType:
                          type: string
                          example: Manual
                        notes:
                          type: string
                          example: 'Test notes'
                        recordedAt:
                          type: string
                          example: '2020-12-01 10:00:00'
      tags:
        - 'Webinar Management API'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                webinarId:
                  type: integer
                  description: 'The ID of the webinar'
                  example: 7
                pageSize:
                  type: integer
                  description: 'The page size of the report'
                  example: 12
                pageNumber:
                  type: integer
                  description: 'The page number of the report'
                  example: 16
                portalId:
                  type: integer
                  description: 'The ID of the portal'
                  example: 14
              required:
                - webinarId
                - pageSize
                - pageNumber
                - portalId
      security: []
  /api/zoom/webhook:
    post:
      summary: 'Handle Zoom Webhook'
      operationId: handleZoomWebhook
      description: 'Receives Zoom webhook events. When a `meeting.ended` event is received, it processes webinar attendance.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Event received'
                properties:
                  message:
                    type: string
                    example: 'Event received'
        204:
          description: ''
      tags:
        - Webinars
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                event:
                  type: string
                  description: 'The Zoom event type.'
                  example: meeting.ended
                payload:
                  type: object
                  description: 'The payload object from Zoom.'
                  example: []
                  properties:
                    object:
                      type: object
                      description: ''
                      example:
                        id: 1234567890
                      properties:
                        id:
                          type: integer
                          description: 'The Zoom meeting ID.'
                          example: 1234567890
              required:
                - event
                - payload
      security: []
  /api/module/webinar/launch:
    get:
      summary: 'Get Launch Details'
      operationId: getLaunchDetails
      description: "Retrieves the launch details for the webinar modules. Returned data includes webinar provider name(like vimeo, zoom, big blue button, etc), whether webinar is created successfully or not, etc\nThis information helps while launching the webinar for learners."
      parameters:
        -
          in: query
          name: moduleId
          description: 'ID of the webinar module.'
          example: '12'
          required: true
          schema:
            type: string
            description: 'ID of the webinar module.'
            example: '12'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: 5
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  provider: zoom
                  webinarDetails:
                    is_success: true
                    message: 'Meeting started successfully'
                    url: 'https://zoom.us/j/11111111111'
                properties:
                  provider:
                    type: string
                    example: zoom
                  webinarDetails:
                    type: object
                    properties:
                      is_success:
                        type: boolean
                        example: true
                      message:
                        type: string
                        example: 'Meeting started successfully'
                      url:
                        type: string
                        example: 'https://zoom.us/j/11111111111'
      tags:
        - Webinars
      security: []
  /api/module/webinar/markComplete:
    put:
      summary: 'Mark Complete Webinar Module'
      operationId: markCompleteWebinarModule
      description: "Updates the status of the webinar module to completed.\nChanges the completion percentage to 100% and marks completed the webinar module."
      parameters:
        -
          in: query
          name: statusRowId
          description: 'ID of the ModuleStatus Row belongs to current webinar module.'
          example: '4'
          required: true
          schema:
            type: string
            description: 'ID of the ModuleStatus Row belongs to current webinar module.'
            example: '4'
        -
          in: query
          name: portalId
          description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'The portal ID to filter users by portal and sub-portals. Use -1 to skip portal filtering.'
            example: 5
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Module completed successfully'
                  course_newly_completed: false
                properties:
                  message:
                    type: string
                    example: 'Module completed successfully'
                  course_newly_completed:
                    type: boolean
                    example: false
      tags:
        - Webinars
      security: []
tags:
  -
    name: Users
    description: "\nYou can perform user management tasks like creating, deleting and updating users."
  -
    name: Accredible
    description: "\nIt allows users to receive digital credentials"
  -
    name: Announcements
    description: "\nThe Announcements module allows you to manage announcement-related operations within the system."
  -
    name: Assignments
    description: "\nAn Assignment Module is a lesson module used as course content. Helps to perform CRUD operation to and for Assignments modules."
  -
    name: 'Audit Logs'
    description: "\nIt allows you to track the user activity in the LMS."
  -
    name: Badge
    description: "\nEndpoints for handling and managing Gamification badges"
  -
    name: Categories
    description: "\nCategories represents Course category, Product category, Question category. Helps performimg operations in all these models."
  -
    name: 'Certificate Templates'
    description: "\nA Certificate template is used to provide to learners. learners can achieve this award by completing the course.\nHelps in performing CRUD operations for and to certificates"
  -
    name: Courses
    description: "\nYou can perform operations like create, edit, delete on courses and its contents."
  -
    name: 'Discount Coupons'
    description: "\nA Coupon is used by the learners to reduce ther price by some discount, provided by the Instructor. \nIt helps for adding/updating/editing discount coupons applied on products."
  -
    name: Discussions
    description: "\nA Discussion module is used as course content and a platform where learners can have discussions. Helps to perform CRUD operation to and for discussion modules."
  -
    name: ECommerce
    description: "\nEndpoints for managing ecommerce settings.\nGetting and setting items status and values for the platform and the products."
  -
    name: 'ECommerce Orders'
    description: "\nAn ECommerce Order is made by the learners when they purchase a product hence course.\nIt helps in managing orders and performing CRUD operation on orders."
  -
    name: 'ECommerce Payments'
    description: "\nEndpoints for managing ecommerce Payment Gateways.\nPayment gateways will be used when your users are purchasing products."
  -
    name: 'ECommerce Products'
    description: "\nA Product will be reached to your learners. Course has to be attached to products so that learners can purchase your courses.\nHelps in performing CRUD operations for and to products."
  -
    name: 'Flash Cards Modules'
    description: "\nA Flash Cards Module is a lesson module used as course content. Helps to perform CRUD operation to and for Flash Cards modules."
  -
    name: 'Front End Webhook API'
    description: "\nEndpoints for Front end Marketing Pages. Send automated notifications to external system when some action happens."
  -
    name: Gamification
    description: "\nEndpoints for managing Gamification settings."
  -
    name: 'General Settings'
    description: "\nGeneral Settings helps in managing general platform settings like site name, timezone, emails etc"
  -
    name: 'Hubspot Integration'
    description: "\nIt allows you to track learner activity and progress in the LMS, and trigger changes in HubSpot data accordingly."
  -
    name: Integrations
    description: "\nAn integration can be used by admins to integrate this platform to other platforms.\nEndpoints helps in performing CRUD operation for and to integration."
  -
    name: 'LTI Integration API'
    description: "\nThis controller handles all API interactions related to Learning Tools Interoperability (LTI) \nintegration. It provides endpoints for managing LTI tool launches, handling authentication, \nand syncing data between the platform and external LTI-compliant systems such as learning management systems (LMS).\n\nEndpoints in this controller facilitate the integration and communication between the platform \nand external educational tools or services via the LTI standard."
  -
    name: Leaderboard
    description: "\nYou can perform operations like create, edit, delete on Leaderboard Tiers."
  -
    name: 'Learning Paths'
    description: ''
  -
    name: Location
    description: "\nYou can perform operations like create, edit, delete on locations"
  -
    name: Media
    description: "\nEndpoints for handling and managing upload/downloads static files, assets and media"
  -
    name: Memberships
    description: "\nMemberships are used to provide content access to users.\nHelps in providing course and standalone modules access to learners"
  -
    name: Menus
    description: "\nMenus are used as front end module for this platform.\nEndpoints for managing menus on marketing front end pages"
  -
    name: Modules
    description: "\nA module is a lesson that you add as course content. Modules could be Text, Video, PDF, SCORM, Quiz, Assignments or Survey.\nHelps in performing CRUD operation to and for modules."
  -
    name: PDFs
    description: "\nA PDF Module is a lesson module used as course content. Helps to perform CRUD operation to and for PDF modules."
  -
    name: Pages
    description: "\nPages are Front end Marketing visuals. Page can be viewed by the different users to interact with this platform.\nEndpoint helps in managing pages."
  -
    name: Portal
    description: "\nThe Portal API controller handles various operations related to the portal's functionality.\n\nAll endpoints within this controller are responsible for providing and managing data \nrelated to the portal's core operations."
  -
    name: Powerpoint
    description: "\nA Powerpoint Module is used as course content. Helps to perform CRUD operation to and for Powerpoint modules."
  -
    name: Questions
    description: "\nManage Questions. Questions can be added in the Quiz module for learners to answer.\nHelps to perform CRUD operations for and to questions."
  -
    name: 'QuickBooks Integration'
    description: "\nThis controller handles all API interactions related to QuickBooks integration.  * \nEndpoints in this controller are responsible for managing QuickBooks-specific operations, \nensuring seamless integration between the system and QuickBooks."
  -
    name: Quizzes
    description: "\nA Quiz Module is a quiz used as course content. Helps to perform CRUD operation to and for quiz modules."
  -
    name: 'SCORM Packages'
    description: "\nSCORM packages can be used in course as course scorm module.\nEndpoints for managing SCORM Packages."
  -
    name: 'SCORMs '
    description: "\nAn SCORM Module is used as course content. Helps to perform CRUD operation to and for SCORM modules."
  -
    name: 'Salesforce Integration'
    description: "\nIt allows you to track learner activity and progress in the LMS, and trigger changes in Salesforce data accordingly."
  -
    name: Staffs
    description: "\nYou can perform staff management tasks like creating, deleting and updating staffs."
  -
    name: 'Subscription Products'
    description: "\nA subscription product whose amount will be paid in subscriptions (in between intervals) by your learners.\nHelps in performing CRUD operations for and to subscription products."
  -
    name: 'Survey Modules'
    description: "\nA survey module is a feedback module that you can add as course content to get learners feedback about your course(How they felt about course, ratings, etc).\nHelps in performing CRUD operation to and for survey modules."
  -
    name: 'Text Modules'
    description: "\nA Text Module is a lesson module used as course content. Helps to perform CRUD operation to and for Text modules."
  -
    name: Videos
    description: "\nA Video Module is a lesson module used as course content. Helps to perform CRUD operation to and for Video modules."
  -
    name: 'Webinar Management API'
    description: "\nThis controller handles all API interactions related to webinar management within the platform. \nIt provides endpoints for creating, updating, deleting, and retrieving webinar details, as well as \nmanaging attendee registrations, webinar sessions, and related content.\n\nEndpoints in this controller are focused on managing the lifecycle of webinars, \nfrom setup to attendee interactions and webinar reporting."
  -
    name: Webinars
    description: "\nA Webinar Module is used as course content. Helps to perform CRUD operation to and for Webinar modules."
