Skip to content

Commit 7727515

Browse files
release: 4.0.alpha (#249)
* chore: go live (#250) * feat(api): update via SDK Studio (#251) * feat(api): update via SDK Studio (#252) * chore: update SDK settings (#253) * release: 0.1.0 --------- Co-authored-by: stainless-app[bot] <142633134+stainless-app[bot]@users.noreply.github.com>
1 parent 44d360a commit 7727515

File tree

311 files changed

+1514
-1514
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

311 files changed

+1514
-1514
lines changed

.devcontainer/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ FROM mcr.microsoft.com/vscode/devcontainers/python:0-${VARIANT}
33

44
USER vscode
55

6-
RUN curl -sSf https://rye.astral.sh/get | RYE_VERSION="0.24.0" RYE_INSTALL_OPTION="--yes" bash
6+
RUN curl -sSf https://rye.astral.sh/get | RYE_VERSION="0.35.0" RYE_INSTALL_OPTION="--yes" bash
77
ENV PATH=/home/vscode/.rye/shims:$PATH
88

99
RUN echo "[[ -d .venv ]] && source .venv/bin/activate" >> /home/vscode/.bashrc

.github/workflows/ci.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ on:
66
pull_request:
77
branches:
88
- v3
9+
- next
910

1011
jobs:
1112
lint:
@@ -21,7 +22,7 @@ jobs:
2122
curl -sSf https://rye.astral.sh/get | bash
2223
echo "$HOME/.rye/shims" >> $GITHUB_PATH
2324
env:
24-
RYE_VERSION: 0.24.0
25+
RYE_VERSION: '0.35.0'
2526
RYE_INSTALL_OPTION: '--yes'
2627

2728
- name: Install dependencies
@@ -41,7 +42,7 @@ jobs:
4142
curl -sSf https://rye.astral.sh/get | bash
4243
echo "$HOME/.rye/shims" >> $GITHUB_PATH
4344
env:
44-
RYE_VERSION: 0.24.0
45+
RYE_VERSION: '0.35.0'
4546
RYE_INSTALL_OPTION: '--yes'
4647

4748
- name: Bootstrap

.github/workflows/create-releases.yml

Lines changed: 0 additions & 38 deletions
This file was deleted.

.github/workflows/handle-release-pr-title-edit.yml

Lines changed: 0 additions & 25 deletions
This file was deleted.

.github/workflows/publish-pypi.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
1-
# workflow for re-running publishing to PyPI in case it fails for some reason
2-
# you can run this workflow by navigating to https://www.github.com/intercom/python-intercom/actions/workflows/publish-pypi.yml
1+
# This workflow is triggered when a GitHub release is created.
2+
# It can also be run manually to re-publish to PyPI in case it failed for some reason.
3+
# You can run this workflow by navigating to https://www.github.com/intercom/python-intercom/actions/workflows/publish-pypi.yml
34
name: Publish PyPI
45
on:
56
workflow_dispatch:
67

8+
release:
9+
types: [published]
10+
711
jobs:
812
publish:
913
name: publish
@@ -17,8 +21,8 @@ jobs:
1721
curl -sSf https://rye.astral.sh/get | bash
1822
echo "$HOME/.rye/shims" >> $GITHUB_PATH
1923
env:
20-
RYE_VERSION: 0.24.0
21-
RYE_INSTALL_OPTION: "--yes"
24+
RYE_VERSION: '0.35.0'
25+
RYE_INSTALL_OPTION: '--yes'
2226

2327
- name: Publish to PyPI
2428
run: |

.github/workflows/release-doctor.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,4 @@ jobs:
1616
run: |
1717
bash ./bin/check-release-environment
1818
env:
19-
STAINLESS_API_KEY: ${{ secrets.STAINLESS_API_KEY }}
2019
PYPI_TOKEN: ${{ secrets.INTERCOM_PYPI_TOKEN || secrets.PYPI_TOKEN }}

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
.prism.log
12
.vscode
23
_dev
34

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "0.0.1"
2+
".": "0.1.0"
33
}

CHANGELOG.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# Changelog
2+
3+
## 0.1.0 (2024-07-17)
4+
5+
Full Changelog: [v0.0.1...v0.1.0](https://github.com/intercom/python-intercom/compare/v0.0.1...v0.1.0)
6+
7+
### Features
8+
9+
* **api:** OpenAPI spec update ([7b99dc3](https://github.com/intercom/python-intercom/commit/7b99dc3ea6ce3c61845510a06f313624d92db628))
10+
* **api:** OpenAPI spec update ([632e659](https://github.com/intercom/python-intercom/commit/632e659f6a0694e1c262e77d8a1da664e67488fa))
11+
* **api:** OpenAPI spec update ([a561dff](https://github.com/intercom/python-intercom/commit/a561dffa1225722412e78890ea2668f58a3d6aa9))
12+
* **api:** update via SDK Studio ([44d360a](https://github.com/intercom/python-intercom/commit/44d360a2e477e2e3cbc2441a2f1ef6dae51e6331))
13+
* **api:** update via SDK Studio ([4f981c5](https://github.com/intercom/python-intercom/commit/4f981c5818eb35a61bcd98952c30322cce6b4e77))
14+
* **api:** update via SDK Studio ([1802937](https://github.com/intercom/python-intercom/commit/1802937e0c6c1366861f4d54d62335b132a6aca8))
15+
* **api:** update via SDK Studio ([c5ee578](https://github.com/intercom/python-intercom/commit/c5ee5781b766f90017b9e40e040dc6ee4010b403))
16+
* **api:** update via SDK Studio ([8d1d513](https://github.com/intercom/python-intercom/commit/8d1d5135cd2ad5a9e92116611e42e5ce471e4c55))
17+
* **api:** update via SDK Studio ([4b7275f](https://github.com/intercom/python-intercom/commit/4b7275faddb82e20d8beb21ad5d1edf8d1ff4e39))
18+
* **api:** update via SDK Studio ([cd48024](https://github.com/intercom/python-intercom/commit/cd480246a573bc08a1cc1182a318f1b3a3b6d709))
19+
* **api:** update via SDK Studio ([dfd8fba](https://github.com/intercom/python-intercom/commit/dfd8fbaea39b1e55b22ee632f7558e96a349e473))
20+
* **api:** update via SDK Studio ([0bd7ae4](https://github.com/intercom/python-intercom/commit/0bd7ae43a2ecfb9f6a190e50a72a139e772a279f))
21+
* **api:** update via SDK Studio ([638c48b](https://github.com/intercom/python-intercom/commit/638c48b6b6aa01b49232d89b8a8e8509055fc062))
22+
* **api:** update via SDK Studio ([bce089e](https://github.com/intercom/python-intercom/commit/bce089efbaf0406130d1ded51c15b752f332bc94))
23+
* **api:** update via SDK Studio ([635b1d1](https://github.com/intercom/python-intercom/commit/635b1d18a40f730ab28529301297a809e1c9d5dc))
24+
* **api:** update via SDK Studio ([b1b9219](https://github.com/intercom/python-intercom/commit/b1b92197c2758c1f121f52cf636033c4b9ba6f42))
25+
* **api:** update via SDK Studio ([e3069e9](https://github.com/intercom/python-intercom/commit/e3069e903f7188941c2a6f69a982bf6e49a04313))
26+
* **api:** update via SDK Studio ([6210114](https://github.com/intercom/python-intercom/commit/62101148adf4ecf0b5aeea53b110feaaba296ede))
27+
* **api:** update via SDK Studio ([aff3c46](https://github.com/intercom/python-intercom/commit/aff3c46f12717bee8bc2a662cd99f34c73e959af))
28+
* **api:** update via SDK Studio ([#251](https://github.com/intercom/python-intercom/issues/251)) ([67e848d](https://github.com/intercom/python-intercom/commit/67e848dfa7681cf197fab68a74d492b6b8f35c39))
29+
* **api:** update via SDK Studio ([#252](https://github.com/intercom/python-intercom/issues/252)) ([0faa8c2](https://github.com/intercom/python-intercom/commit/0faa8c2b3d4557242e1f2ee5dd86bd3c60e11fb7))
30+
31+
32+
### Chores
33+
34+
* go live ([#250](https://github.com/intercom/python-intercom/issues/250)) ([6e3ce75](https://github.com/intercom/python-intercom/commit/6e3ce753e0578fb82d79c77fd4f3dd1184839b4d))
35+
* update SDK settings ([#253](https://github.com/intercom/python-intercom/issues/253)) ([a937722](https://github.com/intercom/python-intercom/commit/a9377223662206e95044d70d44e6f76307204c0d))

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ $ pip install -r requirements-dev.lock
3232
## Modifying/Adding code
3333

3434
Most of the SDK is generated code, and any modified code will be overridden on the next generation. The
35-
`src/python_minus_intercom/lib/` and `examples/` directories are exceptions and will never be overridden.
35+
`src/python_intercom/lib/` and `examples/` directories are exceptions and will never be overridden.
3636

3737
## Adding and running examples
3838

README.md

Lines changed: 19 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -10,25 +10,22 @@ It is generated with [Stainless](https://www.stainlessapi.com/).
1010

1111
## Documentation
1212

13-
The REST API documentation can be found [on developers.intercom.com](https://developers.intercom.com). The full API of this library can be found in [api.md](api.md).
13+
The REST API documentation can be found on [developers.intercom.com](https://developers.intercom.com). The full API of this library can be found in [api.md](api.md).
1414

1515
## Installation
1616

1717
```sh
18-
# install from the production repo
19-
pip install git+ssh://git@github.com/intercom/python-intercom#v3.git
18+
# install from PyPI
19+
pip install python-intercom
2020
```
2121

22-
> [!NOTE]
23-
> Once this package is [published to PyPI](https://app.stainlessapi.com/docs/guides/publish), this will become: `pip install python-intercom`
24-
2522
## Usage
2623

2724
The full API of this library can be found in [api.md](api.md).
2825

2926
```python
3027
import os
31-
from python_minus_intercom import Intercom
28+
from python_intercom import Intercom
3229

3330
client = Intercom(
3431
# This is the default and can be omitted
@@ -53,7 +50,7 @@ Simply import `AsyncIntercom` instead of `Intercom` and use `await` with each AP
5350
```python
5451
import os
5552
import asyncio
56-
from python_minus_intercom import AsyncIntercom
53+
from python_intercom import AsyncIntercom
5754

5855
client = AsyncIntercom(
5956
# This is the default and can be omitted
@@ -84,27 +81,27 @@ Typed requests and responses provide autocomplete and documentation within your
8481

8582
## Handling errors
8683

87-
When the library is unable to connect to the API (for example, due to network connection problems or a timeout), a subclass of `python_minus_intercom.APIConnectionError` is raised.
84+
When the library is unable to connect to the API (for example, due to network connection problems or a timeout), a subclass of `python_intercom.APIConnectionError` is raised.
8885

8986
When the API returns a non-success status code (that is, 4xx or 5xx
90-
response), a subclass of `python_minus_intercom.APIStatusError` is raised, containing `status_code` and `response` properties.
87+
response), a subclass of `python_intercom.APIStatusError` is raised, containing `status_code` and `response` properties.
9188

92-
All errors inherit from `python_minus_intercom.APIError`.
89+
All errors inherit from `python_intercom.APIError`.
9390

9491
```python
95-
import python_minus_intercom
96-
from python_minus_intercom import Intercom
92+
import python_intercom
93+
from python_intercom import Intercom
9794

9895
client = Intercom()
9996

10097
try:
10198
client.me.retrieve()
102-
except python_minus_intercom.APIConnectionError as e:
99+
except python_intercom.APIConnectionError as e:
103100
print("The server could not be reached")
104101
print(e.__cause__) # an underlying Exception, likely raised within httpx.
105-
except python_minus_intercom.RateLimitError as e:
102+
except python_intercom.RateLimitError as e:
106103
print("A 429 status code was received; we should back off a bit.")
107-
except python_minus_intercom.APIStatusError as e:
104+
except python_intercom.APIStatusError as e:
108105
print("Another non-200-range status code was received")
109106
print(e.status_code)
110107
print(e.response)
@@ -132,7 +129,7 @@ Connection errors (for example, due to a network connectivity problem), 408 Requ
132129
You can use the `max_retries` option to configure or disable retry settings:
133130

134131
```python
135-
from python_minus_intercom import Intercom
132+
from python_intercom import Intercom
136133

137134
# Configure the default for all requests:
138135
client = Intercom(
@@ -150,7 +147,7 @@ By default requests time out after 1 minute. You can configure this with a `time
150147
which accepts a float or an [`httpx.Timeout`](https://www.python-httpx.org/advanced/#fine-tuning-the-configuration) object:
151148

152149
```python
153-
from python_minus_intercom import Intercom
150+
from python_intercom import Intercom
154151

155152
# Configure the default for all requests:
156153
client = Intercom(
@@ -200,7 +197,7 @@ if response.my_field is None:
200197
The "raw" Response object can be accessed by prefixing `.with_raw_response.` to any HTTP method call, e.g.,
201198

202199
```py
203-
from python_minus_intercom import Intercom
200+
from python_intercom import Intercom
204201

205202
client = Intercom()
206203
response = client.me.with_raw_response.retrieve()
@@ -210,9 +207,9 @@ me = response.parse() # get the object that `me.retrieve()` would have returned
210207
print(me.id)
211208
```
212209

213-
These methods return an [`APIResponse`](https://github.com/intercom/python-intercom/tree/v3/src/python_minus_intercom/_response.py) object.
210+
These methods return an [`APIResponse`](https://github.com/intercom/python-intercom/tree/v3/src/python_intercom/_response.py) object.
214211

215-
The async client returns an [`AsyncAPIResponse`](https://github.com/intercom/python-intercom/tree/v3/src/python_minus_intercom/_response.py) with the same structure, the only difference being `await`able methods for reading the response content.
212+
The async client returns an [`AsyncAPIResponse`](https://github.com/intercom/python-intercom/tree/v3/src/python_intercom/_response.py) with the same structure, the only difference being `await`able methods for reading the response content.
216213

217214
#### `.with_streaming_response`
218215

@@ -274,7 +271,7 @@ You can directly override the [httpx client](https://www.python-httpx.org/api/#c
274271
- Additional [advanced](https://www.python-httpx.org/advanced/clients/) functionality
275272

276273
```python
277-
from python_minus_intercom import Intercom, DefaultHttpxClient
274+
from python_intercom import Intercom, DefaultHttpxClient
278275

279276
client = Intercom(
280277
# Or use the `INTERCOM_BASE_URL` env var

0 commit comments

Comments
 (0)