from ._base import BaseClient


class AirQualityClient(BaseClient):
    def __init__(self, token, default_days=3, **kwargs):
        super(AirQualityClient, self).__init__(token, **kwargs)
        self._default_days = default_days

    def by_days(self, location, options=None):
        params = self._build_params(
            location,
            options,
            default_days=self._default_days,
            supports_days=True,
        )
        params, headers = self._with_auth(params)
        return self._transport.get("/v2/air/by-days/", params=params, headers=headers)
