AccuWeather Current API

The Current API from AccuWeather — 1 operation(s) for current.

OpenAPI Specification

accuweather-current-api-openapi.yml Raw ↑
openapi: 3.0.1
info:
  title: AccuWeather One Active Storms Current API
  description: AccuWeather's internal product API for the One platform.
  version: v1
tags:
- name: Current
paths:
  /api/current/{locationKey}:
    get:
      tags:
      - Current
      summary: AccuWeather Retrieves a the Latest Weather Conditions for a Location
      parameters:
      - name: locationKey
        in: path
        description: The location key to retrieve weather conditions for
        required: true
        schema:
          type: string
        example: '347628'
      - name: Locale
        in: query
        description: ISO 639-2 and ISO 3166-1 code for the locale
        schema:
          type: string
          example: en-us
        example: en-us
      - name: MeasurementDisplay
        in: query
        description: Display type for weather conditions and distance
        schema:
          $ref: '#/components/schemas/MeasurementDisplayType'
        example: Imperial
      - name: WindUnit
        in: query
        description: Additional display type for wind direction
        schema:
          $ref: '#/components/schemas/WindDirectionDisplayType'
        example: Cardinal
      - name: Theme
        in: query
        description: Theme for the application
        schema:
          $ref: '#/components/schemas/ThemeType'
        example: System
      responses:
        '200':
          description: Current conditions found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FavoriteLocation'
              examples:
                _api_current_locationKey200Example:
                  summary: Default _api_current_locationKey 200 response
                  x-microcks-default: true
                  value:
                    id: '500123'
                    key: '347628'
                    name: New York
                    longName: New York
                    displayName: New York
                    displayTemperature: example-value
                    displayHighTemperature: example-value
                    displayLowTemperature: example-value
                    displayRealFeel: example-value
                    displayRealFeelShade: example-value
                    icon: 6
                    conditions: example-value
                    localTime: example-value
                    color: example-value
                    isBefore7PM: true
                    isDayTime: true
                    minuteCastForecast:
                      summary60: example-value
                      minutes:
                      - displayTime: null
                        minute: null
                        color: null
                        dbz: null
                        precipitationType: null
                    numberOfAlerts: 1
                    latitude: 40.7128
                    longitude: -74.006
        '404':
          description: Response was missing or empty
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
components:
  schemas:
    MeasurementDisplayType:
      enum:
      - Metric
      - Imperial
      - Hybrid
      type: string
    MinuteCastMinute:
      type: object
      properties:
        displayTime:
          type: string
          nullable: true
        minute:
          type: integer
          format: int32
        color:
          type: string
          nullable: true
        dbz:
          type: number
          format: float
          nullable: true
        precipitationType:
          type: string
          nullable: true
      additionalProperties: false
    MinuteCastForecast:
      type: object
      properties:
        summary60:
          type: string
          nullable: true
        minutes:
          type: array
          items:
            $ref: '#/components/schemas/MinuteCastMinute'
          nullable: true
      additionalProperties: false
    ThemeType:
      enum:
      - Light
      - Dark
      - System
      type: string
    WindDirectionDisplayType:
      enum:
      - Cardinal
      - Degrees
      type: string
    FavoriteLocation:
      type: object
      properties:
        id:
          type: string
          nullable: true
        key:
          type: string
          nullable: true
        name:
          type: string
          nullable: true
        longName:
          type: string
          nullable: true
        displayName:
          type: string
          nullable: true
        displayTemperature:
          type: string
          nullable: true
        displayHighTemperature:
          type: string
          nullable: true
        displayLowTemperature:
          type: string
          nullable: true
        displayRealFeel:
          type: string
          nullable: true
        displayRealFeelShade:
          type: string
          nullable: true
        icon:
          type: integer
          format: int32
        conditions:
          type: string
          nullable: true
        localTime:
          type: string
          nullable: true
        color:
          type: string
          nullable: true
        isBefore7PM:
          type: boolean
        isDayTime:
          type: boolean
        minuteCastForecast:
          $ref: '#/components/schemas/MinuteCastForecast'
        numberOfAlerts:
          type: integer
          format: int32
          nullable: true
        latitude:
          type: number
          format: double
          nullable: true
        longitude:
          type: number
          format: double
          nullable: true
      additionalProperties: false