openapi: 3.0.0
info:
  title: Re-Order
  version: 1.0.0
servers:
  - url: http://{{backend_url}}
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
tags:
  - name: Auth
paths:
  /auth/customer/emailpass:
    post:
      tags:
        - Auth
      summary: Get JWT / Login
      requestBody:
        content:
          application/json:
            schema:
              type: object
              example:
                email: customer@gmail.com
                password: supersecret
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /store/customers:
    post:
      tags:
        - Auth
      summary: Register Customer
      requestBody:
        content:
          application/json:
            schema:
              type: object
              example:
                email: customer@gmail.com
                first_name: Customer
                last_name: Example
      security:
        - bearerAuth: []
      parameters:
        - name: x-publishable-api-key
          in: header
          schema:
            type: string
          example: '{{MEDUSA_PUBLISHABLE_API_KEY}}'
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /auth/customer/emailpass/register:
    post:
      tags:
        - Auth
      summary: Get Register Token
      requestBody:
        content:
          application/json:
            schema:
              type: object
              example:
                email: customer@gmail.com
                password: supersecret
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /store/customers/me/orders/{id}:
    post:
      tags:
        - default
      summary: Re-Order
      requestBody:
        content: {}
      security:
        - bearerAuth: []
      parameters:
        - name: x-publishable-api-key
          in: header
          schema:
            type: string
          example: '{{MEDUSA_PUBLISHABLE_API_KEY}}'
        - name: id
          in: path
          schema:
            type: string
          required: true
          example: order_01JTFZF7GZMREV6HXDMFH2YMGC
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
