openapi: 3.0.3
servers:
  - description: Stellastra is a simple API which allows you to easily generate star ratings and reviews for your cybersecurity solution.
    url: https://stellastra.com/api/
    x-last-modified: 1669762495839
info:
  contact:
    email: support@stellastra.com
    name: Stellastra
    url: https://stellastra.com/contact-us
  description: Stellastra makes it easy to get reviews for your cybersecurity solution in real-time with its platform-agnostic REST API.
  termsOfService: https://stellastra.com/terms-and-conditions
  title: Stellastra
  version: "1.0"
  x-logo:
    url: https://res.cloudinary.com/dnutsfp7d/image/upload/v1666387612/Stellastra_iukmts.svg
  x-origin:
    - format: openapi
      url: https://stellastra.com/stellastra.json
      version: "3.0"
  x-providerName: stellastra.com
externalDocs:
  description: Stellastra is a simple API which allows you to easily generate star ratings and reviews for your cybersecurity solution.
  url: https://stellastra.com/docs/api
security:
  - BasicAuth: []
tags: []
paths:
  /post-review:
    description: |-
      import responses 

      body = { 
      user_email = "john.smith@tortosieofdestiny.co.uk",
      user_name = "John",
      star_rated_color = "#e7711b",
      } 

      destination = "https://stellastra.com/api/post-review" 
      your_auth_email = "john.smith@yourcompany.com" 
      key = "b371880dc4cc9f19dcd7241bb1aad9cc2700ab113735f45f50835785d65be292f4b3376a0ee0"

      response = requests.post(destination, auth=(your_auth_email, key), data=body)
    post:
      externalDocs:
        url: https://stellastra.com/docs/api
      parameters:
        - allowEmptyValue: false
          deprecated: false
          description: "User's email to which the review verification will be sent. "
          example:
            user_email: johnsmith@companyxyz.com
          in: query
          name: user_email
          required: true
          schema:
            description: User's email must exist and must not use a professional domain (I.E., not from a free service).
            type: string
          x-last-modified: 1669824515109
        - allowEmptyValue: true
          deprecated: false
          description: "The user's name, defaults to empty string \"\".  Thus, if this is omitted, the email to the user will not use the user's name. "
          example:
            user_name: John
          in: query
          name: user_name
          required: false
          schema:
            type: string
          x-last-modified: 1669823242831
        - allowEmptyValue: false
          deprecated: false
          description: The user's star rating, must be a single integer from [1, 2, 3, 4, 5]
          example:
            rating: 5
          in: query
          name: rating
          required: true
          schema:
            enum:
              - 1
              - 2
              - 3
              - 4
              - 5
            type: integer
          x-last-modified: 1669823314043
      requestBody:
        content:
          application/json:
            schema:
              description: "The user_email must use a professional domain, free domains are not supported. "
              properties:
                rating:
                  example: 5
                  type: integer
                user_email:
                  example: johnsmith@usercompanyxyz.com
                  type: string
                user_name:
                  example: John
                  type: string
              required:
                - user_email
                - rating
              type: object
        description: "The request body requires the user_email and rating. The parameter use_name is optional. "
        required: true
        x-last-modified: 1669833477910
      responses:
        "200":
          content:
            application/json:
              schema:
                description: ""
                example:
                  data: Review posted successfully
                properties:
                  data:
                    example: Review posted successfully
                    type: string
                type: object
          description: A response code of 200 means the request was succesful, and the user has been sent an email confirming their review.
          headers: {}
          links: {}
          x-last-modified: 1669809732680
        "400":
          content:
            application/json:
              schema:
                description: ""
                example:
                  data: "'user_email' is missing"
                properties:
                  data:
                    example: "'user_email' is missing"
                    type: string
                type: object
          description: A status code of 400 is returned when a required parameter is mising, such as 'rating' or 'user_email'.
          x-last-modified: 1669809863611
        "401":
          content:
            application/json:
              schema:
                description: This can appear because the authorization header is missing or malformed, or becuse the auth email and key pair is not authorized.
                example:
                  data: Not authorized, authorization header missing or malformed
                properties:
                  data:
                    example: Not authorized, authorization header missing or malformed
                    type: string
                type: object
          description: This can appear because the authorization header is missing or malformed, or because the auth email and key pair is not authorized.
          x-last-modified: 1669809757498
        "403":
          content:
            application/json:
              schema:
                description: The 403 response can have many detailed response messages related to the user's email address validation
                example:
                  data: The syntax of the user's email is invalid.
                properties:
                  data:
                    example: The syntax of the user's email is invalid.
                    type: string
                type: object
          description: The 403 response can have many detailed response messages related to the user's email address validation
          x-last-modified: 1669809757498
      summary: Posts the user's review to Stellastra
      tags: []
    summary: Only POST
    x-last-modified: 1669762885447
components:
  headers: {}
  parameters: {}
  responses: {}
  schemas: {}
  securitySchemes:
    BasicAuth:
      description: |-
        Basic auth header, a base64 encoding of the auth_email and key, with a simple colon separating. 

        1. base64(auth_email + ":" + key)
        2. base64("johnsmith@yourcompany.com:77rOjc2Y2UyYTliMDFjMTY2ODMyNTIyYjAyNDE4YjRi)
        3. ImpvaG5zbWl0aEB5b3VyY29tcGFueS5jb206NzdyT2pjMlkyVXlZVGxpTURGak1UWTJPRE15TlRJeVlqQXlOREU0WWpSaQ==

        This may already be handled by your HTTPS request library, for example, the Python "requests" library allows for , auth=(admin_email, key), while Axios for Node JS allows auth to be specified as {auth:{username: your_auth_email, password: key}}. 
      scheme: basic
      type: http
      x-last-modified: 1669824185668
