> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fix6.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Climate Data

> Return climate data for a given project ID. Requires that a `project_id` be supplied.

The `period` parameter can be used to define which period to return data for. The default is `monthly`, but can also be
any of `weekly`, or `yearly`. If you are interested in custome aggregation periods please contact us (api@fix6.io).

By default, the `start_date` will be today's date, and the `end_date` will be `2099-12-31`. These can be changed to any
date in the format `YYYY-MM-DD` between the dates `2015-01-01` and `2100-01-01`.

Additionally, the `ssp{xxx}_weight` parameters can be used to weight the SSP scenarios. The default is `ssp126_weight=0.1`,
`ssp245_weight=0.4`, `ssp370_weight=0.4`, and `ssp585_weight=0.1`.
These can be changed to any positive values that sum to 1. This allows the user to weight the scenarios as they see fit,
considering that there are differing opinions as to the likelihood of each scenario (e.g., [1][2]).

[1] https://www.nature.com/articles/d41586-020-00177-3

[2] https://www.pnas.org/doi/full/10.1073/pnas.2007117117



## OpenAPI

````yaml get /projects/{project_id}/climate
openapi: 3.0.2
info:
  title: Fix6 API
  version: 0.2.1
servers: []
security: []
paths:
  /projects/{project_id}/climate:
    get:
      summary: Get Climate Data
      description: >-
        Return climate data for a given project ID. Requires that a `project_id`
        be supplied.


        The `period` parameter can be used to define which period to return data
        for. The default is `monthly`, but can also be

        any of `weekly`, or `yearly`. If you are interested in custome
        aggregation periods please contact us (api@fix6.io).


        By default, the `start_date` will be today's date, and the `end_date`
        will be `2099-12-31`. These can be changed to any

        date in the format `YYYY-MM-DD` between the dates `2015-01-01` and
        `2100-01-01`.


        Additionally, the `ssp{xxx}_weight` parameters can be used to weight the
        SSP scenarios. The default is `ssp126_weight=0.1`,

        `ssp245_weight=0.4`, `ssp370_weight=0.4`, and `ssp585_weight=0.1`.

        These can be changed to any positive values that sum to 1. This allows
        the user to weight the scenarios as they see fit,

        considering that there are differing opinions as to the likelihood of
        each scenario (e.g., [1][2]).


        [1] https://www.nature.com/articles/d41586-020-00177-3


        [2] https://www.pnas.org/doi/full/10.1073/pnas.2007117117
      operationId: get_climate_data_projects__project_id__climate_get
      parameters:
        - required: true
          schema:
            title: Project Id
            type: string
          name: project_id
          in: path
        - required: false
          schema:
            title: Period
            type: string
            default: monthly
          name: period
          in: query
        - required: false
          schema:
            title: Start Date
            type: string
            default: today
          name: start_date
          in: query
        - required: false
          schema:
            title: End Date
            type: string
            default: '2099-12-31'
          name: end_date
          in: query
        - required: false
          schema:
            title: Ssp126 Weight
            type: number
            default: 0.1
          name: ssp126_weight
          in: query
        - required: false
          schema:
            title: Ssp245 Weight
            type: number
            default: 0.4
          name: ssp245_weight
          in: query
        - required: false
          schema:
            title: Ssp370 Weight
            type: number
            default: 0.4
          name: ssp370_weight
          in: query
        - required: false
          schema:
            title: Ssp585 Weight
            type: number
            default: 0.1
          name: ssp585_weight
          in: query
      responses:
        '200':
          description: Climate data for a given project ID.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AggregateCMIP6Frame'
        '409':
          description: Incorrect query parameters passed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPError'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - APIKeyHeader: []
components:
  schemas:
    AggregateCMIP6Frame:
      title: AggregateCMIP6Frame
      required:
        - period
        - project_id
        - lat
        - lon
        - avg_temperature_degC
        - min_temperature_degC
        - max_temperature_degC
        - avg_wind_speed_m_per_s
        - sum_total_precipitation_mm_of_water_equivalent
        - avg_relative_humidity_0_1
      type: object
      properties:
        period:
          title: Period
          type: string
          format: date-time
        project_id:
          title: Project Id
          type: string
        lat:
          title: Lat
          maximum: 90
          minimum: -90
          type: number
        lon:
          title: Lon
          maximum: 180
          minimum: -180
          type: number
        avg_temperature_degC:
          title: Avg Temperature Degc
          type: number
        min_temperature_degC:
          title: Min Temperature Degc
          type: number
        max_temperature_degC:
          title: Max Temperature Degc
          type: number
        avg_wind_speed_m_per_s:
          title: Avg Wind Speed M Per S
          type: number
        sum_total_precipitation_mm_of_water_equivalent:
          title: Sum Total Precipitation Mm Of Water Equivalent
          type: number
        avg_relative_humidity_0_1:
          title: Avg Relative Humidity 0 1
          type: number
    HTTPError:
      title: HTTPError
      required:
        - detail
      type: object
      properties:
        detail:
          title: Detail
          type: string
      example:
        detail: HTTPException raised.
    HTTPValidationError:
      title: HTTPValidationError
      type: object
      properties:
        detail:
          title: Detail
          type: array
          items:
            $ref: '#/components/schemas/ValidationError'
    ValidationError:
      title: ValidationError
      required:
        - loc
        - msg
        - type
      type: object
      properties:
        loc:
          title: Location
          type: array
          items:
            anyOf:
              - type: string
              - type: integer
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
  securitySchemes:
    APIKeyHeader:
      type: apiKey
      in: header
      name: x-api-key

````