Skip to content
This repository was archived by the owner on Apr 23, 2021. It is now read-only.
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
4 changes: 4 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Change Log

## Version 2.20190612.1 (2019-06-26)

* **Bug fix**: `Transaction.Charge` and `Customers.CreateCustomerCard` request objects — now include the `verification_token` required for [Strong Customer Authentication](https://developer.squareup.com/docs/sca-overview).

## Version 2.20190612.0 (2019-06-12)

* **BETA releases**:
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -677,6 +677,7 @@ Class | Method | HTTP request
- [V1UpdateOrderRequestAction](docs/V1UpdateOrderRequestAction.md)
- [V1VariationInventoryAlertType](docs/V1VariationInventoryAlertType.md)
- [V1VariationPricingType](docs/V1VariationPricingType.md)
- [WebhookEvents](docs/WebhookEvents.md)
- [Weekday](docs/Weekday.md)


Expand Down
2 changes: 1 addition & 1 deletion docs/CatalogObject.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

### Description

The wrapper object for object types in the Catalog data model. The type of a particular `CatalogObject` is determined by the value of `type` and only the corresponding data field may be set. - if type = `ITEM`, only `item_data` will be populated and it will contain a valid [CatalogItem](#type-catalogitem) object. - if type = `ITEM_VARIATION`, only `item_variation_data` will be populated and it will contain a valid [CatalogItemVariation](#type-catalogitemvariation) object. - if type = `MODIFIER`, only `modifier_data` will be populated and it will contain a valid [CatalogModifier](#type-catalogmodifier) object. - if type = `MODIFIER_LIST`, only `modifier_list_data` will be populated and it will contain a valid [CatalogModifierList](#type-catalogmodifierlist) object. - if type = `CATEGORY`, only `category_data` will be populated and it will contain a valid [CatalogCategory](#type-catalogcategory) object. - if type = `DISCOUNT`, only `discount_data` will be populated and it will contain a valid [CatalogDiscount](#type-catalogdiscount) object. - if type = `TAX`, only `tax_data` will be populated and it will contain a valid [CatalogTax](#type-catalogtax) object. - if type = `IMAGE`, only `image_data` will be populated and it will contain a valid [CatalogImage](#type-catalogimage) object. For a more detailed discussion of the Catalog data model, please see the [Catalog Overview](/products/catalog/overview).
The wrapper object for object types in the Catalog data model. The type of a particular `CatalogObject` is determined by the value of `type` and only the corresponding data field may be set. - if type = `ITEM`, only `item_data` will be populated and it will contain a valid [CatalogItem](#type-catalogitem) object. - if type = `ITEM_VARIATION`, only `item_variation_data` will be populated and it will contain a valid [CatalogItemVariation](#type-catalogitemvariation) object. - if type = `MODIFIER`, only `modifier_data` will be populated and it will contain a valid [CatalogModifier](#type-catalogmodifier) object. - if type = `MODIFIER_LIST`, only `modifier_list_data` will be populated and it will contain a valid [CatalogModifierList](#type-catalogmodifierlist) object. - if type = `CATEGORY`, only `category_data` will be populated and it will contain a valid [CatalogCategory](#type-catalogcategory) object. - if type = `DISCOUNT`, only `discount_data` will be populated and it will contain a valid [CatalogDiscount](#type-catalogdiscount) object. - if type = `TAX`, only `tax_data` will be populated and it will contain a valid [CatalogTax](#type-catalogtax) object. - if type = `IMAGE`, only `image_data` will be populated and it will contain a valid [CatalogImage](#type-catalogimage) object. For a more detailed discussion of the Catalog data model, please see the [Design a Catalog](/catalog-api/design-a-catalog) guide.

## Properties
Name | Type | Description | Notes
Expand Down
1 change: 1 addition & 0 deletions docs/ChargeRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Name | Type | Description | Notes
**buyer_email_address** | **str** | The buyer's email address, if available. | [optional]
**order_id** | **str** | The ID of the order to associate with this transaction. If you provide this value, the `amount_money` value of your request must __exactly match__ the value of the order's `total_money` field. | [optional]
**additional_recipients** | [**list[AdditionalRecipient]**](AdditionalRecipient.md) | The basic primitive of multi-party transaction. The value is optional. The transaction facilitated by you can be split from here. If you provide this value, the `amount_money` value in your additional_recipients must not be more than 90% of the `amount_money` value in the charge request. The `location_id` must be the valid location of the app owner merchant. This field requires the `PAYMENTS_WRITE_ADDITIONAL_RECIPIENTS` OAuth permission. This field is currently not supported in sandbox. | [optional]
**verification_token** | **str** | An identifying token generated by `SqPaymentForm.verifyBuyer()`. Verification tokens encapsulate customer device information and 3-D Secure challenge results to indicate that Square has verified the buyer identity. | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
5 changes: 3 additions & 2 deletions docs/CreateCustomerCardRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@ Defines the fields that are included in the request body of a request to the Cre
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**card_nonce** | **str** | A card nonce representing the credit card to link to the customer. Card nonces are generated by the `SqPaymentForm` that buyers enter their card information into. See [Embedding the payment form](/payments/sqpaymentform/overview) for more information. __Note:__ Card nonces generated by digital wallets (e.g., Apple Pay) cannot be used to create a customer card. |
**card_nonce** | **str** | A card nonce representing the credit card to link to the customer. Card nonces are generated by the `SqPaymentForm` that buyers enter their card information into. See [Embedding the payment form](/payment-form/payment-form-walkthrough) for more information. __Note:__ Card nonces generated by digital wallets (e.g., Apple Pay) cannot be used to create a customer card. |
**billing_address** | [**Address**](Address.md) | Address information for the card on file. Only the `postal_code` field is required for payments in the US and Canada. | [optional]
**cardholder_name** | **str** | The cardholder's name. | [optional]
**cardholder_name** | **str** | The full name printed on the credit card. | [optional]
**verification_token** | **str** | An identifying token generated by `SqPaymentForm.verifyBuyer()`. Verification tokens encapsulate customer device information and 3-D Secure challenge results to indicate that Square has verified the buyer identity. | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
2 changes: 1 addition & 1 deletion docs/OAuthApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ Assign your **Access Token** from developer portal to the authorization paramete

### Description

`RenewToken` is deprecated. For information about refreshing OAuth access tokens, see [Renew OAuth Token](/authz/oauth/cookbook/oauth-renew). Renews an OAuth access token before it expires. OAuth access tokens besides your application's personal access token expire after __30 days__. You can also renew expired tokens within __15 days__ of their expiration. You cannot renew an access token that has been expired for more than 15 days. Instead, the associated user must re-complete the OAuth flow from the beginning. __Important:__ The `Authorization` header for this endpoint must have the following format: ``` Authorization: Client APPLICATION_SECRET ``` Replace `APPLICATION_SECRET` with the application secret on the Credentials page in the [application dashboard](https://connect.squareup.com/apps).
`RenewToken` is deprecated. For information about refreshing OAuth access tokens, see [Renew OAuth Token](https://developer.squareup.com/docs/oauth-api/cookbook/renew-oauth-tokens). Renews an OAuth access token before it expires. OAuth access tokens besides your application's personal access token expire after __30 days__. You can also renew expired tokens within __15 days__ of their expiration. You cannot renew an access token that has been expired for more than 15 days. Instead, the associated user must re-complete the OAuth flow from the beginning. __Important:__ The `Authorization` header for this endpoint must have the following format: ``` Authorization: Client APPLICATION_SECRET ``` Replace `APPLICATION_SECRET` with the application secret on the Credentials page in the [application dashboard](https://connect.squareup.com/apps).

### Parameters

Expand Down
2 changes: 1 addition & 1 deletion docs/OrderLineItem.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**uid** | **str** | Unique ID that identifies the line item only within this order. This field is read-only. | [optional]
**name** | **str** | The name of the line item. | [optional]
**quantity** | **str** | The quantity purchased, formatted as a decimal number. For example: `\"3\"`. Line items with a `quantity_unit` can have non-integer quantities. For example: `\"1.70000\"`. Orders Hub and older versions of Connect do not support non-integer quantities. See [Decimal quantities with Orders hub and older versions of Connect](/more-apis/orders/overview#decimal-quantities). |
**quantity** | **str** | The quantity purchased, formatted as a decimal number. For example: `\"3\"`. Line items with a `quantity_unit` can have non-integer quantities. For example: `\"1.70000\"`. |
**quantity_unit** | [**OrderQuantityUnit**](OrderQuantityUnit.md) | The unit and precision that this line item's quantity is measured in. | [optional]
**note** | **str** | The note of the line item. | [optional]
**catalog_object_id** | **str** | The [CatalogItemVariation](#type-catalogitemvariation) id applied to this line item. | [optional]
Expand Down
2 changes: 1 addition & 1 deletion docs/OrderQuantityUnit.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Contains the measurement unit for a quantity and a precision which specifies the
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**measurement_unit** | [**MeasurementUnit**](MeasurementUnit.md) | A [MeasurementUnit](#type-measurementunit) that represents the unit of measure for the quantity. | [optional]
**precision** | **int** | For non-integer quantities, represents the number of digits after the decimal point that are recorded for this quantity. For example, a precision of 1 allows quantities like `\"1.0\"` and `\"1.1\"`, but not `\"1.01\"`. Min: 0. Max: 5. Orders Hub and older versions of Connect do not support non-integer quantities. See [Decimal quantities with Orders hub and older versions of Connect](/more-apis/orders/overview#decimal-quantities). | [optional]
**precision** | **int** | For non-integer quantities, represents the number of digits after the decimal point that are recorded for this quantity. For example, a precision of 1 allows quantities like `\"1.0\"` and `\"1.1\"`, but not `\"1.01\"`. Min: 0. Max: 5. | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
4 changes: 2 additions & 2 deletions docs/V1CashDrawerShift.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

### Description

V1CashDrawerShift
Contains details for a single cash drawer shift.

## Properties
Name | Type | Description | Notes
Expand All @@ -17,7 +17,7 @@ Name | Type | Description | Notes
**opening_employee_id** | **str** | The ID of the employee that started the cash drawer shift. | [optional]
**ending_employee_id** | **str** | The ID of the employee that ended the cash drawer shift. | [optional]
**closing_employee_id** | **str** | The ID of the employee that closed the cash drawer shift by auditing the cash drawer's contents. | [optional]
**description** | **str** | The time when the timecard was created, in ISO 8601 format. | [optional]
**description** | **str** | A description of the cash drawer shift. | [optional]
**starting_cash_money** | [**V1Money**](V1Money.md) | The amount of money in the cash drawer at the start of the shift. | [optional]
**cash_payment_money** | [**V1Money**](V1Money.md) | The amount of money added to the cash drawer from cash payments. | [optional]
**cash_refunds_money** | [**V1Money**](V1Money.md) | The amount of money removed from the cash drawer from cash refunds. This value is always negative or zero. | [optional]
Expand Down
2 changes: 1 addition & 1 deletion docs/V1Item.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Name | Type | Description | Notes
**master_image** | [**V1ItemImage**](V1ItemImage.md) | The item's master image, if any. | [optional]
**category** | [**V1Category**](V1Category.md) | The category the item belongs to, if any. | [optional]
**variations** | [**list[V1Variation]**](V1Variation.md) | The item's variations. You must specify at least one variation. | [optional]
**modifier_lists** | [**list[V1Variation]**](V1Variation.md) | The modifier lists that apply to the item, if any. | [optional]
**modifier_lists** | [**list[V1ModifierList]**](V1ModifierList.md) | The modifier lists that apply to the item, if any. | [optional]
**fees** | [**list[V1Fee]**](V1Fee.md) | The fees that apply to the item, if any. | [optional]
**taxable** | **bool** | Deprecated. This field is not used. | [optional]
**category_id** | **str** | The ID of the item's category, if any. | [optional]
Expand Down
15 changes: 15 additions & 0 deletions docs/WebhookEvents.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# WebhookEvents


### Description

The type of an event that triggers a webhook notification to an application.

## Properties
Name | Type
------------ | -------------
**inventory.count.updated** | string

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from setuptools import setup, find_packages

NAME = "squareconnect"
VERSION = "2.20190612.0"
VERSION = "2.20190612.1"



Expand Down
1 change: 1 addition & 0 deletions squareconnect/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -441,6 +441,7 @@
from .models.v1_variation_pricing_type import V1VariationPricingType
from .models.void_transaction_request import VoidTransactionRequest
from .models.void_transaction_response import VoidTransactionResponse
from .models.webhook_events import WebhookEvents
from .models.weekday import Weekday
from .models.workweek_config import WorkweekConfig

Expand Down
2 changes: 1 addition & 1 deletion squareconnect/api_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def __init__(self, configuration=None, header_name=None, header_value=None, cook
self.default_headers[header_name] = header_value
self.cookie = cookie
# Set default User-Agent.
self.user_agent = 'Square-Connect-Python/2.20190612.0'
self.user_agent = 'Square-Connect-Python/2.20190612.1'

@property
def user_agent(self):
Expand Down
2 changes: 1 addition & 1 deletion squareconnect/apis/customers_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def create_customer_card(self, customer_id, body, **kwargs):

:param callback function: The callback function
for asynchronous request. (optional)
:param str customer_id: The ID of the customer to link the card on file to. (required)
:param str customer_id: The Square ID of the customer profile the card is linked to. (required)
:param CreateCustomerCardRequest body: An object containing the fields to POST for the request. See the corresponding object definition for field details. (required)
:return: CreateCustomerCardResponse
If the method is called asynchronously,
Expand Down
2 changes: 1 addition & 1 deletion squareconnect/apis/o_auth_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ def obtain_token(self, body, **kwargs):
def renew_token(self, client_id, body, **kwargs):
"""
RenewToken
`RenewToken` is deprecated. For information about refreshing OAuth access tokens, see [Renew OAuth Token](/authz/oauth/cookbook/oauth-renew). Renews an OAuth access token before it expires. OAuth access tokens besides your application's personal access token expire after __30 days__. You can also renew expired tokens within __15 days__ of their expiration. You cannot renew an access token that has been expired for more than 15 days. Instead, the associated user must re-complete the OAuth flow from the beginning. __Important:__ The `Authorization` header for this endpoint must have the following format: ``` Authorization: Client APPLICATION_SECRET ``` Replace `APPLICATION_SECRET` with the application secret on the Credentials page in the [application dashboard](https://connect.squareup.com/apps).
`RenewToken` is deprecated. For information about refreshing OAuth access tokens, see [Renew OAuth Token](https://developer.squareup.com/docs/oauth-api/cookbook/renew-oauth-tokens). Renews an OAuth access token before it expires. OAuth access tokens besides your application's personal access token expire after __30 days__. You can also renew expired tokens within __15 days__ of their expiration. You cannot renew an access token that has been expired for more than 15 days. Instead, the associated user must re-complete the OAuth flow from the beginning. __Important:__ The `Authorization` header for this endpoint must have the following format: ``` Authorization: Client APPLICATION_SECRET ``` Replace `APPLICATION_SECRET` with the application secret on the Credentials page in the [application dashboard](https://connect.squareup.com/apps).

This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
Expand Down
2 changes: 1 addition & 1 deletion squareconnect/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -229,5 +229,5 @@ def to_debug_report(self):
"OS: {env}\n"\
"Python Version: {pyversion}\n"\
"Version of the API: 2.0\n"\
"SDK Package Version: 2.20190612.0".\
"SDK Package Version: 2.20190612.1".\
format(env=sys.platform, pyversion=sys.version)
1 change: 1 addition & 0 deletions squareconnect/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -441,5 +441,6 @@
from .v1_variation_pricing_type import V1VariationPricingType
from .void_transaction_request import VoidTransactionRequest
from .void_transaction_response import VoidTransactionResponse
from .webhook_events import WebhookEvents
from .weekday import Weekday
from .workweek_config import WorkweekConfig
Loading