Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit4f981c5

Browse files
committed
feat(api): update via SDK Studio
1 parent1802937 commit4f981c5

File tree

299 files changed

+324
-307
lines changed

Some content is hidden

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

299 files changed

+324
-307
lines changed

‎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_intercom/lib/` and`examples/` directories are exceptions and will never be overridden.
35+
`src/python_minus_intercom/lib/` and`examples/` directories are exceptions and will never be overridden.
3636

3737
##Adding and running examples
3838

‎README.md‎

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ The full API of this library can be found in [api.md](api.md).
2828

2929
```python
3030
import os
31-
frompython_intercomimport Intercom
31+
frompython_minus_intercomimport Intercom
3232

3333
client= Intercom(
3434
# This is the default and can be omitted
@@ -53,7 +53,7 @@ Simply import `AsyncIntercom` instead of `Intercom` and use `await` with each AP
5353
```python
5454
import os
5555
import asyncio
56-
frompython_intercomimport AsyncIntercom
56+
frompython_minus_intercomimport AsyncIntercom
5757

5858
client= AsyncIntercom(
5959
# This is the default and can be omitted
@@ -84,27 +84,27 @@ Typed requests and responses provide autocomplete and documentation within your
8484

8585
##Handling errors
8686

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_intercom.APIConnectionError` is raised.
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.
8888

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

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

9494
```python
95-
importpython_intercom
96-
frompython_intercomimport Intercom
95+
importpython_minus_intercom
96+
frompython_minus_intercomimport Intercom
9797

9898
client= Intercom()
9999

100100
try:
101101
client.me.retrieve()
102-
exceptpython_intercom.APIConnectionErroras e:
102+
exceptpython_minus_intercom.APIConnectionErroras e:
103103
print("The server could not be reached")
104104
print(e.__cause__)# an underlying Exception, likely raised within httpx.
105-
exceptpython_intercom.RateLimitErroras e:
105+
exceptpython_minus_intercom.RateLimitErroras e:
106106
print("A 429 status code was received; we should back off a bit.")
107-
exceptpython_intercom.APIStatusErroras e:
107+
exceptpython_minus_intercom.APIStatusErroras e:
108108
print("Another non-200-range status code was received")
109109
print(e.status_code)
110110
print(e.response)
@@ -132,7 +132,7 @@ Connection errors (for example, due to a network connectivity problem), 408 Requ
132132
You can use the`max_retries` option to configure or disable retry settings:
133133

134134
```python
135-
frompython_intercomimport Intercom
135+
frompython_minus_intercomimport Intercom
136136

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

152152
```python
153-
frompython_intercomimport Intercom
153+
frompython_minus_intercomimport Intercom
154154

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

202202
```py
203-
frompython_intercomimport Intercom
203+
frompython_minus_intercomimport Intercom
204204

205205
client= Intercom()
206206
response= client.me.with_raw_response.retrieve()
@@ -210,9 +210,9 @@ me = response.parse() # get the object that `me.retrieve()` would have returned
210210
print(me.id)
211211
```
212212

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

215-
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.
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.
216216

217217
####`.with_streaming_response`
218218

@@ -271,10 +271,10 @@ You can directly override the [httpx client](https://www.python-httpx.org/api/#c
271271

272272
- Support for proxies
273273
- Custom transports
274-
- Additional[advanced](https://www.python-httpx.org/advanced/#client-instances) functionality
274+
- Additional[advanced](https://www.python-httpx.org/advanced/clients/) functionality
275275

276276
```python
277-
frompython_intercomimport Intercom, DefaultHttpxClient
277+
frompython_minus_intercomimport Intercom, DefaultHttpxClient
278278

279279
client= Intercom(
280280
# Or use the `INTERCOM_BASE_URL` env var

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp