Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [1.5.0] - 2021-03-01

### Changed

- Changed base URL from https://api.usepatch.com to https://api.patch.io

## [1.4.0] - 2021-02-15

### Added
Expand Down
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,18 @@
[![PyPI version](https://badge.fury.io/py/patch-api.svg)](https://badge.fury.io/py/patch-api)
[![Discord](https://img.shields.io/discord/733029448558837792)](https://discord.gg/AU8543D)

The official Python library for the [Patch API](https://www.usepatch.com).
The official Python library for the [Patch API](https://www.patch.io).

## Documentation

For a complete API reference, check out [Patch's API Reference.](https://docs.usepatch.com/).
For a complete API reference, check out [Patch's API Reference.](https://docs.patch.io/).

## Installation

Add the library to your `requirements.txt` file:

```txt
patch_api >= 1.4.0
patch_api >= 1.5.0
```

Then run:
Expand Down Expand Up @@ -153,6 +153,7 @@ patch.estimates.retrieve_estimates(page=page)
Projects are the ways Patch takes CO2 out of the air. They can represent reforestation, enhanced weathering, direct air carbon capture, etc. When you place an order via Patch, it is allocated to a project.

When fetching projects, you can supply filters to the query to narrow your result. Currently supported filters are:

- `country`
- `type`
- `minimum_available_mass`
Expand Down
2 changes: 1 addition & 1 deletion patch_api/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

from __future__ import absolute_import

__version__ = "1.4.0"
__version__ = "1.5.0"

# import ApiClient
from patch_api.api_client import ApiClient
Expand Down
2 changes: 1 addition & 1 deletion patch_api/api_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ def __init__(
self.default_headers[header_name] = header_value
self.cookie = cookie
# Set default User-Agent.
self.user_agent = "OpenAPI-Generator/1.4.0/python"
self.user_agent = "OpenAPI-Generator/1.5.0/python"

def __del__(self):
if self._pool:
Expand Down
6 changes: 3 additions & 3 deletions patch_api/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ class Configuration(object):

def __init__(
self,
host="https://api.usepatch.com",
host="https://api.patch.io",
api_key=None,
api_key_prefix=None,
username=None,
Expand Down Expand Up @@ -341,7 +341,7 @@ def to_debug_report(self):
"OS: {env}\n"
"Python Version: {pyversion}\n"
"Version of the API: v1\n"
"SDK Package Version: 1.4.0".format(env=sys.platform, pyversion=sys.version)
"SDK Package Version: 1.5.0".format(env=sys.platform, pyversion=sys.version)
)

def get_host_settings(self):
Expand All @@ -356,7 +356,7 @@ def get_host_settings(self):
"variables": {
"defaultHost": {
"description": "No description provided",
"default_value": "api.usepatch.com",
"default_value": "api.patch.io",
}
},
}
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
from setuptools import setup, find_packages # noqa: H301

NAME = "patch-api"
VERSION = "1.4.0"
VERSION = "1.5.0"
# To install the library, run the following
#
# python setup.py install
Expand Down