Uploaded image for project: 'Subscription Watch'
  1. Subscription Watch
  2. SWATCH-1535

update swatch-producer-aws openapi yaml to include usable examples

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Won't Do
    • Icon: Normal Normal
    • None
    • None
    • None
    • False
    • Hide

      None

      Show
      None
    • False

      If you use the example currently defined, exceptions are thrown.  The example doesn't use defined enums values for `billing_provider`, `uom`, `sla`, `usage`.

      Example of a working payload:

      {
        "account_number": "string",
        "org_id": "string",
        "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
        "billing_provider": "red hat",
        "billing_account_id": "string",
        "snapshot_date": "2022-03-10T12:15:50-04:00",
        "product_id": "string",
        "sla": "Premium",
        "usage": "Production",
        "uom": "Cores",
        "value": 0,
        "billing_factor": 0,
        "vendor_product_code": "string"
      } 

       

      Reproducer Steps:

      1. Start swatch-producer-aws 
        1. DEV_MODE=true ./gradlew :swatch-producer-aws:quarkusDev 
      1. Navigate to http://localhost:8000/q/dev-ui/io.quarkus.quarkus-smallrye-openapi/swagger-ui 
      2. Under POST /api/swatch-producer-aws/internal/aws/billable_usage, click the Try it out button
      3. Hit execute without modifying the example payload

       

              lburnett0 Lindsey Burnett
              lburnett0 Lindsey Burnett
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: