Skip to content

Commit 47fafb6

Browse files
wickerpopstarPayPalServerSDKsPatrick Powers
authored
1.1.0 Release (#25)
* Automated commit message * Add changelog --------- Co-authored-by: PayPalServerSDKs <server-sdks@paypal.com> Co-authored-by: Patrick Powers <patickpowers@hey.com>
1 parent 4ca4ed5 commit 47fafb6

File tree

226 files changed

+2303
-1524
lines changed

Some content is hidden

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

226 files changed

+2303
-1524
lines changed

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
## 1.1.0
2+
- Added new models to support Apple Pay, Google Pay
3+
- Expanded models to support additional optional fields
4+
- Bug fixes
5+
- Documentation updates
6+
7+
## 1.0.0
8+
- GA Release for Orders, Payments, and Vault APIs

README.md

Lines changed: 41 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -6,49 +6,46 @@
66
### Important Notes
77

88
- **Available Features:** This SDK currently contains only 3 of PayPal's API endpoints. Additional endpoints and functionality will be added in the future.
9-
- **API Changes:** Expect potential changes in APIs and features as we finalize the product.
109

1110
### Information
1211

1312
The PayPal Server SDK provides integration access to the PayPal REST APIs. The API endpoints are divided into distinct controllers:
1413

15-
- Orders Controller: <a href="https://developer.paypal.com/docs/api/orders/v2/">Orders API v2</a>
16-
- Payments Controller: <a href="https://developer.paypal.com/docs/api/payments/v2/">Payments API v2</a>
17-
- Vault Controller: <a href="https://developer.paypal.com/docs/api/payment-tokens/v3/">Payment Method Tokens API v3</a> *Available in the US only.*
18-
19-
Find out more here: [https://developer.paypal.com/docs/api/orders/v2/](https://developer.paypal.com/docs/api/orders/v2/)
14+
- Orders Controller: [Orders API v2](https://developer.paypal.com/docs/api/orders/v2/)
15+
- Payments Controller: [Payments API v2](https://developer.paypal.com/docs/api/payments/v2
16+
- Vault Controller: [Payment Method Tokens API v3](https://developer.paypal.com/docs/api/payment-tokens/v3/) *Available in the US only.*
2017

2118
## Install the Package
2219

2320
The package is compatible with Python versions `3.7+`.
2421
Install the package from PyPi using the following pip command:
2522

2623
```bash
27-
pip install paypal-server-sdk==1.0.0
24+
pip install paypal-server-sdk==1.1.0
2825
```
2926

3027
You can also view the package at:
31-
https://pypi.python.org/pypi/paypal-server-sdk/1.0.0
28+
https://pypi.python.org/pypi/paypal-server-sdk/1.1.0
3229

3330
## Initialize the API Client
3431

35-
**_Note:_** Documentation for the client can be found [here.](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/client.md)
32+
**_Note:_** Documentation for the client can be found [here.](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/client.md)
3633

3734
The following parameters are configurable for the API Client:
3835

3936
| Parameter | Type | Description |
4037
| --- | --- | --- |
41-
| `environment` | `Environment` | The API environment. <br> **Default: `Environment.SANDBOX`** |
42-
| `http_client_instance` | `HttpClient` | The Http Client passed from the sdk user for making requests |
43-
| `override_http_client_configuration` | `bool` | The value which determines to override properties of the passed Http Client from the sdk user |
44-
| `http_call_back` | `HttpCallBack` | The callback value that is invoked before and after an HTTP call is made to an endpoint |
45-
| `timeout` | `float` | The value to use for connection timeout. <br> **Default: 60** |
46-
| `max_retries` | `int` | The number of times to retry an endpoint call if it fails. <br> **Default: 0** |
47-
| `backoff_factor` | `float` | A backoff factor to apply between attempts after the second try. <br> **Default: 2** |
48-
| `retry_statuses` | `Array of int` | The http statuses on which retry is to be done. <br> **Default: [408, 413, 429, 500, 502, 503, 504, 521, 522, 524]** |
49-
| `retry_methods` | `Array of string` | The http methods on which retry is to be done. <br> **Default: ['GET', 'PUT']** |
50-
| `logging_configuration` | [`LoggingConfiguration`](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/logging-configuration.md) | The SDK logging configuration for API calls |
51-
| `client_credentials_auth_credentials` | [`ClientCredentialsAuthCredentials`](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/auth/oauth-2-client-credentials-grant.md) | The credential object for OAuth 2 Client Credentials Grant |
38+
| environment | `Environment` | The API environment. <br> **Default: `Environment.SANDBOX`** |
39+
| http_client_instance | `HttpClient` | The Http Client passed from the sdk user for making requests |
40+
| override_http_client_configuration | `bool` | The value which determines to override properties of the passed Http Client from the sdk user |
41+
| http_call_back | `HttpCallBack` | The callback value that is invoked before and after an HTTP call is made to an endpoint |
42+
| timeout | `float` | The value to use for connection timeout. <br> **Default: 60** |
43+
| max_retries | `int` | The number of times to retry an endpoint call if it fails. <br> **Default: 0** |
44+
| backoff_factor | `float` | A backoff factor to apply between attempts after the second try. <br> **Default: 2** |
45+
| retry_statuses | `Array of int` | The http statuses on which retry is to be done. <br> **Default: [408, 413, 429, 500, 502, 503, 504, 521, 522, 524]** |
46+
| retry_methods | `Array of string` | The http methods on which retry is to be done. <br> **Default: ['GET', 'PUT']** |
47+
| logging_configuration | [`LoggingConfiguration`](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/logging-configuration.md) | The SDK logging configuration for API calls |
48+
| client_credentials_auth_credentials | [`ClientCredentialsAuthCredentials`](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/auth/oauth-2-client-credentials-grant.md) | The credential object for OAuth 2 Client Credentials Grant |
5249

5350
The API client can be initialized as follows:
5451

@@ -86,22 +83,33 @@ The SDK can be configured to use a different environment for making API calls. A
8683

8784
This API uses the following authentication schemes.
8885

89-
* [`Oauth2 (OAuth 2 Client Credentials Grant)`](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/auth/oauth-2-client-credentials-grant.md)
86+
* [`Oauth2 (OAuth 2 Client Credentials Grant)`](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/auth/oauth-2-client-credentials-grant.md)
9087

9188
## List of APIs
9289

93-
* [Orders](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/controllers/orders.md)
94-
* [Payments](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/controllers/payments.md)
95-
* [Vault](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/controllers/vault.md)
90+
* [Orders](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/controllers/orders.md)
91+
* [Payments](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/controllers/payments.md)
92+
* [Vault](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/controllers/vault.md)
93+
94+
## SDK Infrastructure
95+
96+
### Configuration
97+
98+
* [AbstractLogger](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/abstract-logger.md)
99+
* [LoggingConfiguration](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/logging-configuration.md)
100+
* [RequestLoggingConfiguration](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/request-logging-configuration.md)
101+
* [ResponseLoggingConfiguration](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/response-logging-configuration.md)
102+
103+
### HTTP
104+
105+
* [HttpResponse](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/http-response.md)
106+
* [HttpRequest](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/http-request.md)
96107

97-
## Classes Documentation
108+
### Utilities
98109

99-
* [Utility Classes](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/utility-classes.md)
100-
* [HttpResponse](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/http-response.md)
101-
* [HttpRequest](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/http-request.md)
102-
* [ApiResponse](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/api-response.md)
103-
* [LoggingConfiguration](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/logging-configuration.md)
104-
* [RequestLoggingConfiguration](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/request-logging-configuration.md)
105-
* [ResponseLoggingConfiguration](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/response-logging-configuration.md)
106-
* [AbstractLogger](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.0.0/doc/abstract-logger.md)
110+
* [ApiResponse](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/api-response.md)
111+
* [ApiHelper](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/api-helper.md)
112+
* [HttpDateTime](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/http-date-time.md)
113+
* [RFC3339DateTime](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/rfc3339-date-time.md)
114+
* [UnixDateTime](https://www.github.com/paypal/PayPal-Python-Server-SDK/tree/1.1.0/doc/unix-date-time.md)
107115

doc/abstract-logger.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11

2-
# AbstractLogger Class
2+
# AbstractLogger
33

44
An abstract class for custom logger implementation.
55

doc/api-helper.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
2+
# ApiHelper
3+
4+
A utility class for processing API Calls. Also contains classes for supporting standard datetime formats.
5+
6+
## Methods
7+
8+
| Name | Description |
9+
| --- | --- |
10+
| json_deserialize | Deserializes a JSON string to a Python dictionary. |
11+

doc/api-response.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ An object with the response value as well as other useful information such as st
1111
| reason_phrase | `str` | The reason phrase returned with the status code. |
1212
| headers | `dict[str, str]` | The HTTP response headers. |
1313
| text | `str` | The raw response body as a string. |
14-
| request | [`HttpRequest`](http-request.md) | The original HTTP request sent. |
14+
| request | [`HttpRequest`](../doc/http-request.md) | The original HTTP request sent. |
1515
| body | `Any` | The parsed response data, if applicable. |
1616

17-
## Example Usage
17+
## Usage Example
1818

1919
```python
2020
try:

doc/client.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,17 @@ The following parameters are configurable for the API Client:
55

66
| Parameter | Type | Description |
77
| --- | --- | --- |
8-
| `environment` | `Environment` | The API environment. <br> **Default: `Environment.SANDBOX`** |
9-
| `http_client_instance` | `HttpClient` | The Http Client passed from the sdk user for making requests |
10-
| `override_http_client_configuration` | `bool` | The value which determines to override properties of the passed Http Client from the sdk user |
11-
| `http_call_back` | `HttpCallBack` | The callback value that is invoked before and after an HTTP call is made to an endpoint |
12-
| `timeout` | `float` | The value to use for connection timeout. <br> **Default: 60** |
13-
| `max_retries` | `int` | The number of times to retry an endpoint call if it fails. <br> **Default: 0** |
14-
| `backoff_factor` | `float` | A backoff factor to apply between attempts after the second try. <br> **Default: 2** |
15-
| `retry_statuses` | `Array of int` | The http statuses on which retry is to be done. <br> **Default: [408, 413, 429, 500, 502, 503, 504, 521, 522, 524]** |
16-
| `retry_methods` | `Array of string` | The http methods on which retry is to be done. <br> **Default: ['GET', 'PUT']** |
17-
| `logging_configuration` | [`LoggingConfiguration`](logging-configuration.md) | The SDK logging configuration for API calls |
18-
| `client_credentials_auth_credentials` | [`ClientCredentialsAuthCredentials`](auth/oauth-2-client-credentials-grant.md) | The credential object for OAuth 2 Client Credentials Grant |
8+
| environment | `Environment` | The API environment. <br> **Default: `Environment.SANDBOX`** |
9+
| http_client_instance | `HttpClient` | The Http Client passed from the sdk user for making requests |
10+
| override_http_client_configuration | `bool` | The value which determines to override properties of the passed Http Client from the sdk user |
11+
| http_call_back | `HttpCallBack` | The callback value that is invoked before and after an HTTP call is made to an endpoint |
12+
| timeout | `float` | The value to use for connection timeout. <br> **Default: 60** |
13+
| max_retries | `int` | The number of times to retry an endpoint call if it fails. <br> **Default: 0** |
14+
| backoff_factor | `float` | A backoff factor to apply between attempts after the second try. <br> **Default: 2** |
15+
| retry_statuses | `Array of int` | The http statuses on which retry is to be done. <br> **Default: [408, 413, 429, 500, 502, 503, 504, 521, 522, 524]** |
16+
| retry_methods | `Array of string` | The http methods on which retry is to be done. <br> **Default: ['GET', 'PUT']** |
17+
| logging_configuration | [`LoggingConfiguration`](../doc/logging-configuration.md) | The SDK logging configuration for API calls |
18+
| client_credentials_auth_credentials | [`ClientCredentialsAuthCredentials`](auth/oauth-2-client-credentials-grant.md) | The credential object for OAuth 2 Client Credentials Grant |
1919

2020
The API client can be initialized as follows:
2121

0 commit comments

Comments
 (0)