openapi: 3.0.3
info:
  title: 'ShopReviews API Documentation'
  description: ''
  version: 1.0.0
servers:
  -
    url: 'https://reviewsatellite.local.com'
paths:
  /api/v1/login:
    post:
      summary: 'User Login'
      description: ''
      parameters:
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses: {  }
      tags:
        - 'Authentication Endpoints'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                email:
                  type: string
                  description: 'Must be a valid email address.'
                  example: rowe.dalton@example.net
                password:
                  type: string
                  description: ''
                  example: possimus
              required:
                - email
                - password
      security: []
  /api/v1/forgot-password:
    post:
      summary: 'Forgot Password'
      description: ''
      parameters:
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses: {  }
      tags:
        - 'Authentication Endpoints'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                email:
                  type: string
                  description: 'Must be a valid email address.'
                  example: irma39@example.org
              required:
                - email
      security: []
  /api/v1/register:
    post:
      summary: 'Register a User'
      description: ''
      parameters:
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses: {  }
      tags:
        - 'Authentication Endpoints'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                company_name:
                  type: string
                  description: validation.max.
                  example: bdvcvelaicckhfgnlrxjphouzldgwqgzlwmotmjlkrvaagyjidjifxkeydjufpjnntcrvvyznfazjklibnyj
                first_name:
                  type: string
                  description: validation.max.
                  example: fjedqcilseeqooywesoxdrqwsloownzutfibeomywnqyvnqqemzmtkbqqqbeokcquganwgwwurmyoznk
                last_name:
                  type: string
                  description: validation.max.
                  example: lykimeovnvlkzvxxjxcypevdalcwwenilnhrwqrnftjxmjgvoqgscbqegpnzzjnwsdjbelmepldsdvwb
                email:
                  type: string
                  description: 'Must be a valid email address.'
                  example: korey.kertzmann@example.com
                password:
                  type: string
                  description: validation.min.
                  example: xgigo
              required:
                - company_name
                - first_name
                - last_name
                - email
                - password
      security: []
  /api/oauth/generate-url:
    get:
      summary: 'Generate OAuth Url'
      description: ''
      parameters:
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: 'request is invalid #473298'
                properties:
                  error:
                    type: string
                    example: 'request is invalid #473298'
      tags:
        - 'Authentication Endpoints'
      security: []
  /api/oauth/approval:
    post:
      summary: 'Approve OAuth Request'
      description: ''
      parameters:
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses: {  }
      tags:
        - 'Authentication Endpoints'
      security: []
  '/api/v1/oauth/code-exchange/{code}':
    get:
      summary: 'Exchange Code for Access Token'
      description: ''
      parameters:
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: 'Trying to get property ''response'' of non-object'
                properties:
                  error:
                    type: string
                    example: 'Trying to get property ''response'' of non-object'
      tags:
        - 'Authentication Endpoints'
      security: []
    parameters:
      -
        in: path
        name: code
        description: ''
        example: illo
        required: true
        schema:
          type: string
  '/api/v1/reviews/mapped/{companyUuid}':
    get:
      summary: 'List Reviews'
      description: 'This endpoint will return the list of reviews by how the user mapped it on the backend'
      parameters:
        -
          in: query
          name: websiteUuid
          description: 'Filter by website by providing the UUID of the website'
          example: beatae
          required: false
          schema:
            type: string
            description: 'Filter by website by providing the UUID of the website'
            example: beatae
        -
          in: query
          name: sourceUuid
          description: 'Filter by source by providing the UUID of the source'
          example: velit
          required: false
          schema:
            type: string
            description: 'Filter by source by providing the UUID of the source'
            example: velit
        -
          in: query
          name: reviewUuid
          description: 'Filter by review by providing the UUID of the review'
          example: eius
          required: false
          schema:
            type: string
            description: 'Filter by review by providing the UUID of the review'
            example: eius
        -
          in: query
          name: includeSummary
          description: 'Option to include additional summary data Default: false'
          example: false
          required: false
          schema:
            type: boolean
            description: 'Option to include additional summary data Default: false'
            example: false
        -
          in: query
          name: includeMappings
          description: 'Option to include additional summary data Default: true'
          example: true
          required: false
          schema:
            type: boolean
            description: 'Option to include additional summary data Default: true'
            example: true
        -
          in: query
          name: includeOriginalResponse
          description: 'Option to include additional summary data Default: false'
          example: true
          required: false
          schema:
            type: boolean
            description: 'Option to include additional summary data Default: false'
            example: true
        -
          in: query
          name: startDate
          description: 'date Filter by start date (Format: YYYY-MM-DD)'
          example: '2022-06-01'
          required: false
          schema:
            type: string
            description: 'date Filter by start date (Format: YYYY-MM-DD)'
            example: '2022-06-01'
        -
          in: query
          name: endDate
          description: 'date Filter by end date (Format: YYYY-MM-DD)'
          example: '2022-06-30'
          required: false
          schema:
            type: string
            description: 'date Filter by end date (Format: YYYY-MM-DD)'
            example: '2022-06-30'
        -
          in: query
          name: offset
          description: 'Specify from which row we want the data to retrieve. (default 0)'
          example: 15
          required: false
          schema:
            type: integer
            description: 'Specify from which row we want the data to retrieve. (default 0)'
            example: 15
        -
          in: query
          name: limit
          description: 'Specify the number of records to return. (default 100)'
          example: 2
          required: false
          schema:
            type: integer
            description: 'Specify the number of records to return. (default 100)'
            example: 2
        -
          in: header
          name: Authorization
          description: ''
          example: 'Bearer {YOUR_AUTH_KEY}'
          schema:
            type: string
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: Unauthenticated.
                properties:
                  error:
                    type: string
                    example: Unauthenticated.
      tags:
        - Endpoints
    parameters:
      -
        in: path
        name: companyUuid
        description: 'The UUID of the company'
        example: explicabo
        required: true
        schema:
          type: string
  /api/v1/websites:
    get:
      summary: 'List Websites'
      description: 'This endpoint will return a list of websites under the account.'
      parameters:
        -
          in: query
          name: websiteUuid
          description: 'An optional parameter to filter by website. Provide UUID of the website to filter.'
          example: null
          required: false
          schema:
            type: string
            description: 'An optional parameter to filter by website. Provide UUID of the website to filter.'
            example: null
        -
          in: header
          name: Authorization
          description: ''
          example: 'Bearer {YOUR_AUTH_KEY}'
          schema:
            type: string
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: Unauthenticated.
                properties:
                  error:
                    type: string
                    example: Unauthenticated.
      tags:
        - Endpoints
  /api/v1/sources:
    get:
      summary: 'List Sources'
      description: 'This endpoint will return a list of sources under the account'
      parameters:
        -
          in: header
          name: Authorization
          description: ''
          example: 'Bearer {YOUR_AUTH_KEY}'
          schema:
            type: string
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: Unauthenticated.
                properties:
                  error:
                    type: string
                    example: Unauthenticated.
      tags:
        - Endpoints
    parameters:
      -
        in: path
        name: websiteUuid
        description: 'Optional parameter. optional The UUID of the website'
        required: true
        schema:
          type: string
        examples:
          omitted:
            summary: 'When the value is omitted'
            value: ''
          present:
            summary: 'When the value is present'
            value: quia
  /api/v1/reviews:
    get:
      summary: 'List System Reviews'
      description: 'This endpoint will return a list of reviews under the account.'
      parameters:
        -
          in: query
          name: sourceUuid
          description: 'An optional parameter to filter reviews by source. Provide UUID of the source to filter.'
          example: null
          required: false
          schema:
            type: string
            description: 'An optional parameter to filter reviews by source. Provide UUID of the source to filter.'
            example: null
        -
          in: query
          name: rating
          description: 'An optional parameter to filter reviews by rating. Value can be 1 to 5.'
          example: 5
          required: false
          schema:
            type: integer
            description: 'An optional parameter to filter reviews by rating. Value can be 1 to 5.'
            example: 5
        -
          in: query
          name: dateBefore
          description: 'date An optional parameter to filter reviews by rating.'
          example: '2023-06-01'
          required: false
          schema:
            type: string
            description: 'date An optional parameter to filter reviews by rating.'
            example: '2023-06-01'
        -
          in: query
          name: dateAfter
          description: 'date An optional parameter to filter reviews by rating.'
          example: '2023-01-01'
          required: false
          schema:
            type: string
            description: 'date An optional parameter to filter reviews by rating.'
            example: '2023-01-01'
        -
          in: query
          name: year
          description: 'An optional parameter to filter reviews by year it was posted.'
          example: 2023
          required: false
          schema:
            type: integer
            description: 'An optional parameter to filter reviews by year it was posted.'
            example: 2023
        -
          in: query
          name: limit
          description: 'The number of records to show (Default: 100).'
          example: 100
          required: false
          schema:
            type: integer
            description: 'The number of records to show (Default: 100).'
            example: 100
        -
          in: query
          name: page
          description: 'The page number of records to show (Default: 1).'
          example: 1
          required: false
          schema:
            type: integer
            description: 'The page number of records to show (Default: 1).'
            example: 1
        -
          in: header
          name: Authorization
          description: ''
          example: 'Bearer {YOUR_AUTH_KEY}'
          schema:
            type: string
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: Unauthenticated.
                properties:
                  error:
                    type: string
                    example: Unauthenticated.
      tags:
        - Endpoints
  '/api/v1/reviews/{id}':
    get:
      summary: 'Get Review'
      description: 'This endpoint will return the information of a review'
      parameters:
        -
          in: header
          name: Authorization
          description: ''
          example: 'Bearer {YOUR_AUTH_KEY}'
          schema:
            type: string
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: Unauthenticated.
                properties:
                  error:
                    type: string
                    example: Unauthenticated.
      tags:
        - Endpoints
    parameters:
      -
        in: path
        name: id
        description: 'The id of the review to view'
        example: 20
        required: true
        schema:
          type: integer
  /api/v1/reviews/unread/user:
    get:
      summary: 'Get Unread Reviews by a User'
      description: 'This endpoint will return the unread reviews by the user'
      parameters:
        -
          in: header
          name: Authorization
          description: ''
          example: 'Bearer {YOUR_AUTH_KEY}'
          schema:
            type: string
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: Unauthenticated.
                properties:
                  error:
                    type: string
                    example: Unauthenticated.
      tags:
        - Endpoints
  '/api/v1/reviews/read/user/{reviewId}':
    post:
      summary: 'Mark Unread Reviews as Read'
      description: 'This endpoint will mark an unread review as read'
      parameters:
        -
          in: header
          name: Authorization
          description: ''
          example: 'Bearer {YOUR_AUTH_KEY}'
          schema:
            type: string
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses: {  }
      tags:
        - Endpoints
    parameters:
      -
        in: path
        name: reviewId
        description: 'Optional parameter. The id of the review to be marked as read. (You can leave as blank to mark all unread reviews as read)'
        required: true
        schema:
          type: integer
        examples:
          omitted:
            summary: 'When the value is omitted'
            value: ''
          present:
            summary: 'When the value is present'
            value: 11
  /api/v1/user:
    get:
      summary: 'Get Current User Details'
      description: 'This endpoint will return the details of the current active user.'
      parameters:
        -
          in: header
          name: Authorization
          description: ''
          example: 'Bearer {YOUR_AUTH_KEY}'
          schema:
            type: string
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: Unauthenticated.
                properties:
                  error:
                    type: string
                    example: Unauthenticated.
      tags:
        - Endpoints
  /api/v1/rating-overview:
    get:
      summary: 'Get Rating Overview'
      description: 'This endpoint will return the count and the rating data of the reviews on the account.'
      parameters:
        -
          in: header
          name: Authorization
          description: ''
          example: 'Bearer {YOUR_AUTH_KEY}'
          schema:
            type: string
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: Unauthenticated.
                properties:
                  error:
                    type: string
                    example: Unauthenticated.
      tags:
        - Endpoints
  /api/v1/company:
    get:
      summary: 'Get Company Details'
      description: 'This endpoint will return the details of the company.'
      parameters:
        -
          in: header
          name: Authorization
          description: ''
          example: 'Bearer {YOUR_AUTH_KEY}'
          schema:
            type: string
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: Unauthenticated.
                properties:
                  error:
                    type: string
                    example: Unauthenticated.
      tags:
        - Endpoints
  /api/v1/platforms:
    get:
      summary: 'List Platform'
      description: 'This endpoint will return a list of platforms available on the account.'
      parameters:
        -
          in: header
          name: Content-Type
          description: ''
          example: application/json
          schema:
            type: string
        -
          in: header
          name: Accept
          description: ''
          example: application/json
          schema:
            type: string
      responses:
        400:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  error: Unauthenticated.
                properties:
                  error:
                    type: string
                    example: Unauthenticated.
      tags:
        - Endpoints
      security: []
tags:
  -
    name: 'Authentication Endpoints'
    description: 'Login endpoint'
  -
    name: Endpoints
    description: ''
components:
  securitySchemes:
    default:
      type: http
      scheme: bearer
      description: ''
security:
  -
    default: []
