

swagger: "2.0"
info:
  description: "Dashboard API for several use."
  version: 1.0.0
  title: SS6 Dashboard
  termsOfService: "http://transformore.net"
  contact:
    email: ss6@ppa.co.id
host: api12.ppa-mhu.net
basePath: /v2
schemes:
  - http
paths:
  "/operation/prodVHMS?start={dateStart}&end={dateEnd}&model={model}":
    get:
      tags:
        - operation
      summary: Find data Prodty VHMS 
      description: Returns Prodty VHMS 
      operationId: prodVHMS
      produces:
        - application/xml
        - application/json
      parameters:
        - name: dateStart
          in: path
          description: date start for filtering
          required: true
          type: date
        - name: dateEnd
          in: path
          description: date end for filtering
          required: true
          type: date
        - name: model
          in: path
          description: model unit hauler
          required: true
          type: varchar
      responses:
        "200":
          description: successful operation
          schema:
            $ref: "#/definitions/Operation"
      security:
        - api_key: []
  "/operation/ProdFilter?start={dateStart}&end={dateEnd}&metode={metode}":
    get:
      tags:
        - operation
      summary: Find data production
      description: Returns Production
      operationId: productionFilter
      produces:
        - application/xml
        - application/json
      parameters:
        - name: dateStart
          in: path
          description: date start for filtering
          required: true
          type: date
        - name: dateEnd
          in: path
          description: date end for filtering
          required: true
          type: date
        - name: metode
          in: path
          description: select metode production (TC / JS)
          required: true
          type: varchar
      responses:
        "200":
          description: successful operation
          schema:
            $ref: "#/definitions/Operation"
      security:
        - api_key: []
  "/operation/CostParameter?start={dateStart}&end={dateEnd}&activity={activity}":
    get:
      tags:
        - operation
      summary: Find data Cost Parameter
      description: Returns Cost Parameter
      operationId: productionMonthly
      produces:
        - application/xml
        - application/json
      parameters:
        - name: dateStart
          in: path
          description: date start for filtering
          required: true
          type: date
        - name: dateEnd
          in: path
          description: date end for filtering
          required: true
          type: date
        - name: activity
          in: path
          description: select id activity operation
          required: true
          type: varchar
      responses:
        "200":
          description: successful operation
          schema:
            $ref: "#/definitions/Operation"
      security:
        - api_key: []
  "/api/cico/gainloss/daily":
    get:
      tags:
        - Cico
      summary: Retrieve CICO Gain Loss Daily data
      parameters:
        - in: query
          name: start
          schema:
            type: string
          required: true
          description: Start date (YYYY-MM-DD)
        - in: query
          name: end
          schema:
            type: string
          required: true
          description: End date (YYYY-MM-DD)
        - in: query
          name: flag
          schema:
            type: string
          required: false
          description: Flag parameter (report or all)
          example: all
        - in: query
          name: pit
          schema:
            type: string
          required: false
          description: Pit parameter
      responses:
        "200":
          description: successful operation
          schema:
            $ref: "#/definitions/Operation"
      security:
        - api_key: []    
# securityDefinitions:
# petstore_auth:
#   type: oauth2
#   authorizationUrl: 'http://petstore.swagger.io/api/oauth/dialog'
#   flow: implicit
#   scopes:
#     'write:pets': modify pets in your account
#     'read:pets': read your pets
# api_key:
#   type: apiKey
#   name: api_key
#   in: header
definitions:
  Operation:
    title: a Production
    description: A Production
    type: object
    required:
      - name
      - photoUrls
    properties:
      id:
        type: integer
        format: int64
      name:
        type: string
        example: doggie
      photoUrls:
        type: array
        xml:
          name: photoUrl
          wrapped: true
        items:
          type: string
      tags:
        type: array
        xml:
          name: tag
          wrapped: true
      status:
        type: string
        description: pet status in the store
        enum:
          - available
          - pending
          - sold
    xml:
      name: Pet
  ApiResponse:
    title: An uploaded response
    description: Describes the result of uploading an image resource
    type: object
    properties:
      code:
        type: integer
        format: int32
      type:
        type: string
      message:
        type: string
  #issue: https://github.com/swagger-api/swagger-codegen/issues/7980
  Amount:
    type: object
    description: >
      some description
    properties:
      value:
        format: double
        type: number
        minimum: 0.01
        maximum: 1000000000000000
        description: >
          some description
      currency:
        $ref: "#/definitions/Currency"
    required:
      - value
      - currency
  Currency:
    type: string
    pattern: "^[A-Z]{3,3}$"
    description: >
      some description
