From d3a11ee90b08ff58ce1f1d87c49a82081f73c90e Mon Sep 17 00:00:00 2001 From: autobot Date: Wed, 15 Nov 2023 06:47:01 +0000 Subject: [PATCH] Generated PR for Release: 33.0.0.20231115 --- doc/api/labor.md | 22 ++++-- doc/client.md | 6 +- doc/models/catalog-item.md | 11 --- doc/models/catalog-modifier-list.md | 43 ------------ doc/models/catalog-object-batch.md | 58 --------------- doc/models/catalog-object.md | 58 --------------- .../change-billing-anchor-date-response.md | 70 ++++++++++++------- doc/models/create-shift-request.md | 8 ++- doc/models/create-shift-response.md | 5 ++ doc/models/get-shift-response.md | 5 ++ doc/models/get-team-member-wage-response.md | 1 + doc/models/list-team-member-wages-response.md | 4 ++ doc/models/obtain-token-response.md | 4 +- doc/models/search-shifts-response.md | 10 +++ doc/models/shift-wage.md | 4 +- doc/models/shift.md | 14 +++- doc/models/team-member-wage.md | 1 + doc/models/update-shift-request.md | 8 ++- doc/models/update-shift-response.md | 5 ++ pyproject.toml | 2 +- square/api/base_api.py | 2 +- square/client.py | 6 +- square/configuration.py | 2 +- 23 files changed, 132 insertions(+), 217 deletions(-) diff --git a/doc/api/labor.md b/doc/api/labor.md index 9561fb0a..8c36e7ea 100644 --- a/doc/api/labor.md +++ b/doc/api/labor.md @@ -354,15 +354,16 @@ This method returns a `ApiResponse` instance. The `body` property of this instan ```python body = { 'shift': { - 'start_at': '2019-01-25T03:11:00-05:00', 'location_id': 'PAA1RJZZKXBFG', + 'start_at': '2019-01-25T03:11:00-05:00', 'end_at': '2019-01-25T13:11:00-05:00', 'wage': { 'title': 'Barista', 'hourly_rate': { 'amount': 1100, 'currency': 'USD' - } + }, + 'tip_eligible': True }, 'breaks': [ { @@ -374,7 +375,11 @@ body = { 'end_at': '2019-01-25T06:16:00-05:00' } ], - 'team_member_id': 'ormj0jJJZ5OZIzxrZYJI' + 'team_member_id': 'ormj0jJJZ5OZIzxrZYJI', + 'declared_cash_tip_money': { + 'amount': 500, + 'currency': 'USD' + } }, 'idempotency_key': 'HIDSNG5KS478L' } @@ -554,15 +559,16 @@ id = 'id0' body = { 'shift': { - 'start_at': '2019-01-25T03:11:00-05:00', 'location_id': 'PAA1RJZZKXBFG', + 'start_at': '2019-01-25T03:11:00-05:00', 'end_at': '2019-01-25T13:11:00-05:00', 'wage': { 'title': 'Bartender', 'hourly_rate': { 'amount': 1500, 'currency': 'USD' - } + }, + 'tip_eligible': True }, 'breaks': [ { @@ -576,7 +582,11 @@ body = { } ], 'version': 1, - 'team_member_id': 'ormj0jJJZ5OZIzxrZYJI' + 'team_member_id': 'ormj0jJJZ5OZIzxrZYJI', + 'declared_cash_tip_money': { + 'amount': 500, + 'currency': 'USD' + } } } diff --git a/doc/client.md b/doc/client.md index 7e76991a..9446a0b9 100644 --- a/doc/client.md +++ b/doc/client.md @@ -5,7 +5,7 @@ The following parameters are configurable for the API Client: | Parameter | Type | Description | | --- | --- | --- | -| `square_version` | `str` | Square Connect API versions
*Default*: `'2023-10-18'` | +| `square_version` | `str` | Square Connect API versions
*Default*: `'2023-11-15'` | | `custom_url` | `str` | Sets the base URL requests are made to. Defaults to `https://connect.squareup.com`
*Default*: `'https://connect.squareup.com'` | | `environment` | `string` | The API environment.
**Default: `production`** | | `http_client_instance` | `HttpClient` | The Http Client passed from the sdk user for making requests | @@ -25,7 +25,7 @@ The API client can be initialized as follows: ```python from square.client import Client client = Client( - square_version='2023-10-18', + square_version='2023-11-15', access_token='AccessToken' ) ``` @@ -48,7 +48,7 @@ API calls return an `ApiResponse` object that includes the following fields: ```python from square.client import Client client = Client( - square_version='2023-10-18', + square_version='2023-11-15', access_token='AccessToken' ) diff --git a/doc/models/catalog-item.md b/doc/models/catalog-item.md index e037ee90..de07c9dd 100644 --- a/doc/models/catalog-item.md +++ b/doc/models/catalog-item.md @@ -35,17 +35,6 @@ A [CatalogObject](../../doc/models/catalog-object.md) instance of the `ITEM` typ ```json { - "object": { - "id": "#Cocoa", - "item_data": { - "abbreviation": "Ch", - "description": "Hot chocolate", - "name": "Cocoa", - "visibility": "PRIVATE" - }, - "present_at_all_locations": true, - "type": "ITEM" - }, "name": "name6", "description": "description6", "abbreviation": "abbreviation8", diff --git a/doc/models/catalog-modifier-list.md b/doc/models/catalog-modifier-list.md index 605f93de..c3cb017b 100644 --- a/doc/models/catalog-modifier-list.md +++ b/doc/models/catalog-modifier-list.md @@ -26,49 +26,6 @@ the modifier list are allowed. ```json { - "id": "#MilkType", - "modifier_list_data": { - "allow_quantities": false, - "modifiers": [ - { - "modifier_data": { - "name": "Whole Milk", - "price_money": { - "amount": 0, - "currency": "USD" - } - }, - "present_at_all_locations": true, - "type": "MODIFIER" - }, - { - "modifier_data": { - "name": "Almond Milk", - "price_money": { - "amount": 250, - "currency": "USD" - } - }, - "present_at_all_locations": true, - "type": "MODIFIER" - }, - { - "modifier_data": { - "name": "Soy Milk", - "price_money": { - "amount": 250, - "currency": "USD" - } - }, - "present_at_all_locations": true, - "type": "MODIFIER" - } - ], - "name": "Milk Type", - "selection_type": "SINGLE" - }, - "present_at_all_locations": true, - "type": "MODIFIER_LIST", "name": "name4", "ordinal": 226, "selection_type": "SINGLE", diff --git a/doc/models/catalog-object-batch.md b/doc/models/catalog-object-batch.md index 01635bc7..4d13d1cc 100644 --- a/doc/models/catalog-object-batch.md +++ b/doc/models/catalog-object-batch.md @@ -21,19 +21,6 @@ A batch of catalog objects. { "type": "PRICING_RULE", "id": "id6", - "item_data": { - "object": { - "id": "#Cocoa", - "item_data": { - "abbreviation": "Ch", - "description": "Hot chocolate", - "name": "Cocoa", - "visibility": "PRIVATE" - }, - "present_at_all_locations": true, - "type": "ITEM" - } - }, "category_data": { "object": { "category_data": { @@ -73,51 +60,6 @@ A batch of catalog objects. "type": "DISCOUNT" } }, - "modifier_list_data": { - "id": "#MilkType", - "modifier_list_data": { - "allow_quantities": false, - "modifiers": [ - { - "modifier_data": { - "name": "Whole Milk", - "price_money": { - "amount": 0, - "currency": "USD" - } - }, - "present_at_all_locations": true, - "type": "MODIFIER" - }, - { - "modifier_data": { - "name": "Almond Milk", - "price_money": { - "amount": 250, - "currency": "USD" - } - }, - "present_at_all_locations": true, - "type": "MODIFIER" - }, - { - "modifier_data": { - "name": "Soy Milk", - "price_money": { - "amount": 250, - "currency": "USD" - } - }, - "present_at_all_locations": true, - "type": "MODIFIER" - } - ], - "name": "Milk Type", - "selection_type": "SINGLE" - }, - "present_at_all_locations": true, - "type": "MODIFIER_LIST" - }, "modifier_data": { "object": { "modifier_data": { diff --git a/doc/models/catalog-object.md b/doc/models/catalog-object.md index 3cc9ff8c..d54c51a3 100644 --- a/doc/models/catalog-object.md +++ b/doc/models/catalog-object.md @@ -55,19 +55,6 @@ For a more detailed discussion of the Catalog data model, please see the { "type": "TAX", "id": "id4", - "item_data": { - "object": { - "id": "#Cocoa", - "item_data": { - "abbreviation": "Ch", - "description": "Hot chocolate", - "name": "Cocoa", - "visibility": "PRIVATE" - }, - "present_at_all_locations": true, - "type": "ITEM" - } - }, "category_data": { "object": { "category_data": { @@ -107,51 +94,6 @@ For a more detailed discussion of the Catalog data model, please see the "type": "DISCOUNT" } }, - "modifier_list_data": { - "id": "#MilkType", - "modifier_list_data": { - "allow_quantities": false, - "modifiers": [ - { - "modifier_data": { - "name": "Whole Milk", - "price_money": { - "amount": 0, - "currency": "USD" - } - }, - "present_at_all_locations": true, - "type": "MODIFIER" - }, - { - "modifier_data": { - "name": "Almond Milk", - "price_money": { - "amount": 250, - "currency": "USD" - } - }, - "present_at_all_locations": true, - "type": "MODIFIER" - }, - { - "modifier_data": { - "name": "Soy Milk", - "price_money": { - "amount": 250, - "currency": "USD" - } - }, - "present_at_all_locations": true, - "type": "MODIFIER" - } - ], - "name": "Milk Type", - "selection_type": "SINGLE" - }, - "present_at_all_locations": true, - "type": "MODIFIER_LIST" - }, "modifier_data": { "object": { "modifier_data": { diff --git a/doc/models/change-billing-anchor-date-response.md b/doc/models/change-billing-anchor-date-response.md index 20613df8..7878fa75 100644 --- a/doc/models/change-billing-anchor-date-response.md +++ b/doc/models/change-billing-anchor-date-response.md @@ -20,33 +20,12 @@ Defines output parameters in a request to the ```json { - "errors": [ - { - "category": "MERCHANT_SUBSCRIPTION_ERROR", - "code": "MAP_KEY_LENGTH_TOO_LONG", - "detail": "detail6", - "field": "field4" - }, - { - "category": "MERCHANT_SUBSCRIPTION_ERROR", - "code": "MAP_KEY_LENGTH_TOO_LONG", - "detail": "detail6", - "field": "field4" - } - ], - "subscription": { - "id": "id4", - "location_id": "location_id8", - "plan_variation_id": "plan_variation_id8", - "customer_id": "customer_id2", - "start_date": "start_date8" - }, "actions": [ { - "id": "id8", - "type": "RESUME", - "effective_date": "effective_date8", - "monthly_billing_anchor_date": 186, + "effective_date": "2023-11-01", + "id": "f0a1dfdc-675b-3a14-a640-99f7ac1cee83", + "monthly_billing_anchor_date": 1, + "type": "CHANGE_BILLING_ANCHOR_DATE", "phases": [ { "uid": "uid0", @@ -68,6 +47,47 @@ Defines output parameters in a request to the } ] } + ], + "subscription": { + "created_at": "2023-06-20T21:53:10Z", + "customer_id": "CHFGVKYY8RSV93M5KCYTG4PN0G", + "id": "9ba40961-995a-4a3d-8c53-048c40cafc13", + "location_id": "S8GWD5R9QB376", + "monthly_billing_anchor_date": 20, + "phases": [ + { + "order_template_id": "E6oBY5WfQ2eN4pkYZwq4ka6n7KeZY", + "ordinal": 0, + "plan_phase_uid": "C66BKH3ASTDYGJJCEZXQQSS7", + "uid": "98d6f53b-40e1-4714-8827-032fd923be25" + } + ], + "plan_variation_id": "FQ7CDXXWSLUJRPM3GFJSJGZ7", + "price_override_money": { + "amount": 2000, + "currency": "USD" + }, + "source": { + "name": "My Application" + }, + "status": "ACTIVE", + "timezone": "America/Los_Angeles", + "version": 3, + "start_date": "start_date8" + }, + "errors": [ + { + "category": "MERCHANT_SUBSCRIPTION_ERROR", + "code": "MAP_KEY_LENGTH_TOO_LONG", + "detail": "detail6", + "field": "field4" + }, + { + "category": "MERCHANT_SUBSCRIPTION_ERROR", + "code": "MAP_KEY_LENGTH_TOO_LONG", + "detail": "detail6", + "field": "field4" + } ] } ``` diff --git a/doc/models/create-shift-request.md b/doc/models/create-shift-request.md index 7debcdd4..c41f6aa0 100644 --- a/doc/models/create-shift-request.md +++ b/doc/models/create-shift-request.md @@ -30,6 +30,10 @@ Represents a request to create a `Shift`. "start_at": "2019-01-25T06:11:00-05:00" } ], + "declared_cash_tip_money": { + "amount": 500, + "currency": "USD" + }, "end_at": "2019-01-25T13:11:00-05:00", "location_id": "PAA1RJZZKXBFG", "start_at": "2019-01-25T03:11:00-05:00", @@ -39,7 +43,9 @@ Represents a request to create a `Shift`. "amount": 1100, "currency": "USD" }, - "title": "Barista" + "tip_eligible": true, + "title": "Barista", + "job_id": "job_id0" }, "id": "id4", "employee_id": "employee_id4", diff --git a/doc/models/create-shift-response.md b/doc/models/create-shift-response.md index 255fbad8..aed66fe8 100644 --- a/doc/models/create-shift-response.md +++ b/doc/models/create-shift-response.md @@ -33,6 +33,10 @@ the request resulted in errors. } ], "created_at": "2019-02-28T00:39:02Z", + "declared_cash_tip_money": { + "amount": 500, + "currency": "USD" + }, "employee_id": "ormj0jJJZ5OZIzxrZYJI", "end_at": "2019-01-25T13:11:00-05:00", "id": "K0YH4CV5462JB", @@ -49,6 +53,7 @@ the request resulted in errors. "currency": "USD" }, "job_id": "FzbJAtt9qEWncK1BWgVCxQ6M", + "tip_eligible": true, "title": "Barista" } }, diff --git a/doc/models/get-shift-response.md b/doc/models/get-shift-response.md index adc4f545..dad2a4e8 100644 --- a/doc/models/get-shift-response.md +++ b/doc/models/get-shift-response.md @@ -33,6 +33,10 @@ the request resulted in errors. } ], "created_at": "2019-02-27T00:12:12Z", + "declared_cash_tip_money": { + "amount": 500, + "currency": "USD" + }, "employee_id": "D71KRMQof6cXGUW0aAv7", "end_at": "2019-02-23T21:00:00-05:00", "id": "T35HMQSN89SV4", @@ -49,6 +53,7 @@ the request resulted in errors. "currency": "USD" }, "job_id": "N4YKVLzFj3oGtNocqoYHYpW3", + "tip_eligible": true, "title": "Cashier" } }, diff --git a/doc/models/get-team-member-wage-response.md b/doc/models/get-team-member-wage-response.md index 4598156f..4f712877 100644 --- a/doc/models/get-team-member-wage-response.md +++ b/doc/models/get-team-member-wage-response.md @@ -28,6 +28,7 @@ the request resulted in errors. "id": "pXS3qCv7BERPnEGedM4S8mhm", "job_id": "jxJNN6eCJsLrhg5UFJrDWDGE", "team_member_id": "33fJchumvVdJwxV0H6L9", + "tip_eligible": false, "title": "Manager" }, "errors": [ diff --git a/doc/models/list-team-member-wages-response.md b/doc/models/list-team-member-wages-response.md index daafbf38..0e81819d 100644 --- a/doc/models/list-team-member-wages-response.md +++ b/doc/models/list-team-member-wages-response.md @@ -30,6 +30,7 @@ a set of `TeamMemberWage` objects. "id": "pXS3qCv7BERPnEGedM4S8mhm", "job_id": "jxJNN6eCJsLrhg5UFJrDWDGE", "team_member_id": "33fJchumvVdJwxV0H6L9", + "tip_eligible": false, "title": "Manager" }, { @@ -40,6 +41,7 @@ a set of `TeamMemberWage` objects. "id": "rZduCkzYDUVL3ovh1sQgbue6", "job_id": "gcbz15vKGnMKmaWJJ152kjim", "team_member_id": "33fJchumvVdJwxV0H6L9", + "tip_eligible": true, "title": "Cook" }, { @@ -50,6 +52,7 @@ a set of `TeamMemberWage` objects. "id": "FxLbs5KpPUHa8wyt5ctjubDX", "job_id": "FzbJAtt9qEWncK1BWgVCxQ6M", "team_member_id": "33fJchumvVdJwxV0H6L9", + "tip_eligible": true, "title": "Barista" }, { @@ -60,6 +63,7 @@ a set of `TeamMemberWage` objects. "id": "vD1wCgijMDR3cX5TPnu7VXto", "job_id": "N4YKVLzFj3oGtNocqoYHYpW3", "team_member_id": "33fJchumvVdJwxV0H6L9", + "tip_eligible": true, "title": "Cashier" } ], diff --git a/doc/models/obtain-token-response.md b/doc/models/obtain-token-response.md index fc37879d..64f5a8bb 100644 --- a/doc/models/obtain-token-response.md +++ b/doc/models/obtain-token-response.md @@ -9,14 +9,14 @@ | Name | Type | Tags | Description | | --- | --- | --- | --- | -| `access_token` | `str` | Optional | A valid OAuth access token. OAuth access tokens are 64 bytes long.
Provide the access token in a header with every request to Connect API
endpoints. For more information, see [OAuth API: Walkthrough](https://developer.squareup.com/docs/oauth-api/walkthrough).
**Constraints**: *Minimum Length*: `2`, *Maximum Length*: `1024` | +| `access_token` | `str` | Optional | A valid OAuth access token.
Provide the access token in a header with every request to Connect API
endpoints. For more information, see [OAuth API: Walkthrough](https://developer.squareup.com/docs/oauth-api/walkthrough).
**Constraints**: *Minimum Length*: `2`, *Maximum Length*: `1024` | | `token_type` | `str` | Optional | This value is always _bearer_.
**Constraints**: *Minimum Length*: `2`, *Maximum Length*: `10` | | `expires_at` | `str` | Optional | The date when the `access_token` expires, in [ISO 8601](http://www.iso.org/iso/home/standards/iso8601.htm) format.
**Constraints**: *Minimum Length*: `20`, *Maximum Length*: `48` | | `merchant_id` | `str` | Optional | The ID of the authorizing merchant's business.
**Constraints**: *Minimum Length*: `8`, *Maximum Length*: `191` | | `subscription_id` | `str` | Optional | __LEGACY FIELD__. The ID of a subscription plan the merchant signed up
for. The ID is only present if the merchant signed up for a subscription plan during authorization. | | `plan_id` | `str` | Optional | __LEGACY FIELD__. The ID of the subscription plan the merchant signed
up for. The ID is only present if the merchant signed up for a subscription plan during
authorization. | | `id_token` | `str` | Optional | The OpenID token belonging to this person. This token is only present if the
OPENID scope is included in the authorization request. | -| `refresh_token` | `str` | Optional | A refresh token. OAuth refresh tokens are 64 bytes long.
For more information, see [Refresh, Revoke, and Limit the Scope of OAuth Tokens](https://developer.squareup.com/docs/oauth-api/refresh-revoke-limit-scope).
**Constraints**: *Minimum Length*: `2`, *Maximum Length*: `1024` | +| `refresh_token` | `str` | Optional | A refresh token.
For more information, see [Refresh, Revoke, and Limit the Scope of OAuth Tokens](https://developer.squareup.com/docs/oauth-api/refresh-revoke-limit-scope).
**Constraints**: *Minimum Length*: `2`, *Maximum Length*: `1024` | | `short_lived` | `bool` | Optional | A Boolean indicating that the access token is a short-lived access token.
The short-lived access token returned in the response expires in 24 hours. | | `errors` | [`List Error`](../../doc/models/error.md) | Optional | Any errors that occurred during the request. | | `refresh_token_expires_at` | `str` | Optional | The date when the `refresh_token` expires, in [ISO 8601](http://www.iso.org/iso/home/standards/iso8601.htm) format.
**Constraints**: *Minimum Length*: `20`, *Maximum Length*: `48` | diff --git a/doc/models/search-shifts-response.md b/doc/models/search-shifts-response.md index 8affa070..d33e8019 100644 --- a/doc/models/search-shifts-response.md +++ b/doc/models/search-shifts-response.md @@ -35,6 +35,10 @@ the request resulted in errors. } ], "created_at": "2019-01-24T01:12:03Z", + "declared_cash_tip_money": { + "amount": 500, + "currency": "USD" + }, "employee_id": "ormj0jJJZ5OZIzxrZYJI", "end_at": "2019-01-21T13:11:00-05:00", "id": "X714F3HA6D1PT", @@ -51,6 +55,7 @@ the request resulted in errors. "currency": "USD" }, "job_id": "FzbJAtt9qEWncK1BWgVCxQ6M", + "tip_eligible": true, "title": "Barista" } }, @@ -76,6 +81,10 @@ the request resulted in errors. } ], "created_at": "2019-01-23T23:32:45Z", + "declared_cash_tip_money": { + "amount": 0, + "currency": "USD" + }, "employee_id": "33fJchumvVdJwxV0H6L9", "end_at": "2019-01-22T13:02:00-05:00", "id": "GDHYBZYWK0P2V", @@ -92,6 +101,7 @@ the request resulted in errors. "currency": "USD" }, "job_id": "gcbz15vKGnMKmaWJJ152kjim", + "tip_eligible": true, "title": "Cook" } } diff --git a/doc/models/shift-wage.md b/doc/models/shift-wage.md index 53a9d76c..3749244a 100644 --- a/doc/models/shift-wage.md +++ b/doc/models/shift-wage.md @@ -14,6 +14,7 @@ The hourly wage rate used to compensate an employee for this shift. | `title` | `str` | Optional | The name of the job performed during this shift. | | `hourly_rate` | [`Money`](../../doc/models/money.md) | Optional | Represents an amount of money. `Money` fields can be signed or unsigned.
Fields that do not explicitly define whether they are signed or unsigned are
considered unsigned and can only hold positive amounts. For signed fields, the
sign of the value indicates the purpose of the money transfer. See
[Working with Monetary Amounts](https://developer.squareup.com/docs/build-basics/working-with-monetary-amounts)
for more information. | | `job_id` | `str` | Optional | The id of the job performed during this shift. Square
labor-reporting UIs might group shifts together by id. This cannot be used to retrieve the job. | +| `tip_eligible` | `bool` | Optional | Whether team members are eligible for tips when working this job. | ## Example (as JSON) @@ -24,7 +25,8 @@ The hourly wage rate used to compensate an employee for this shift. "amount": 172, "currency": "OMR" }, - "job_id": "job_id2" + "job_id": "job_id2", + "tip_eligible": false } ``` diff --git a/doc/models/shift.md b/doc/models/shift.md index 2613b7e9..4359c586 100644 --- a/doc/models/shift.md +++ b/doc/models/shift.md @@ -15,7 +15,7 @@ taken during the shift. | --- | --- | --- | --- | | `id` | `str` | Optional | The UUID for this object.
**Constraints**: *Maximum Length*: `255` | | `employee_id` | `str` | Optional | The ID of the employee this shift belongs to. DEPRECATED at version 2020-08-26. Use `team_member_id` instead. | -| `location_id` | `str` | Optional | The ID of the location this shift occurred at. The location should be based on
where the employee clocked in. | +| `location_id` | `str` | Required | The ID of the location this shift occurred at. The location should be based on
where the employee clocked in.
**Constraints**: *Minimum Length*: `1` | | `timezone` | `str` | Optional | The read-only convenience value that is calculated from the location based
on the `location_id`. Format: the IANA timezone database identifier for the
location timezone. | | `start_at` | `str` | Required | RFC 3339; shifted to the location timezone + offset. Precision up to the
minute is respected; seconds are truncated.
**Constraints**: *Minimum Length*: `1` | | `end_at` | `str` | Optional | RFC 3339; shifted to the timezone + offset. Precision up to the minute is
respected; seconds are truncated. | @@ -26,6 +26,7 @@ taken during the shift. | `created_at` | `str` | Optional | A read-only timestamp in RFC 3339 format; presented in UTC. | | `updated_at` | `str` | Optional | A read-only timestamp in RFC 3339 format; presented in UTC. | | `team_member_id` | `str` | Optional | The ID of the team member this shift belongs to. Replaced `employee_id` at version "2020-08-26". | +| `declared_cash_tip_money` | [`Money`](../../doc/models/money.md) | Optional | Represents an amount of money. `Money` fields can be signed or unsigned.
Fields that do not explicitly define whether they are signed or unsigned are
considered unsigned and can only hold positive amounts. For signed fields, the
sign of the value indicates the purpose of the money transfer. See
[Working with Monetary Amounts](https://developer.squareup.com/docs/build-basics/working-with-monetary-amounts)
for more information. | ## Example (as JSON) @@ -36,7 +37,16 @@ taken during the shift. "location_id": "location_id4", "timezone": "timezone0", "start_at": "start_at2", - "end_at": "end_at0" + "end_at": "end_at0", + "wage": { + "title": "title8", + "hourly_rate": { + "amount": 172, + "currency": "OMR" + }, + "job_id": "job_id0", + "tip_eligible": false + } } ``` diff --git a/doc/models/team-member-wage.md b/doc/models/team-member-wage.md index 952fe0ba..79cd43a6 100644 --- a/doc/models/team-member-wage.md +++ b/doc/models/team-member-wage.md @@ -17,6 +17,7 @@ specified by the `title` property of this object. | `title` | `str` | Optional | The job title that this wage relates to. | | `hourly_rate` | [`Money`](../../doc/models/money.md) | Optional | Represents an amount of money. `Money` fields can be signed or unsigned.
Fields that do not explicitly define whether they are signed or unsigned are
considered unsigned and can only hold positive amounts. For signed fields, the
sign of the value indicates the purpose of the money transfer. See
[Working with Monetary Amounts](https://developer.squareup.com/docs/build-basics/working-with-monetary-amounts)
for more information. | | `job_id` | `str` | Optional | An identifier for the job that this wage relates to. This cannot be
used to retrieve the job. | +| `tip_eligible` | `bool` | Optional | Whether team members are eligible for tips when working this job. | ## Example (as JSON) diff --git a/doc/models/update-shift-request.md b/doc/models/update-shift-request.md index 0b943b5b..1242f632 100644 --- a/doc/models/update-shift-request.md +++ b/doc/models/update-shift-request.md @@ -29,6 +29,10 @@ A request to update a `Shift` object. "start_at": "2019-01-25T06:11:00-05:00" } ], + "declared_cash_tip_money": { + "amount": 500, + "currency": "USD" + }, "end_at": "2019-01-25T13:11:00-05:00", "location_id": "PAA1RJZZKXBFG", "start_at": "2019-01-25T03:11:00-05:00", @@ -39,7 +43,9 @@ A request to update a `Shift` object. "amount": 1500, "currency": "USD" }, - "title": "Bartender" + "tip_eligible": true, + "title": "Bartender", + "job_id": "job_id0" }, "id": "id4", "employee_id": "employee_id4", diff --git a/doc/models/update-shift-response.md b/doc/models/update-shift-response.md index 3761ede1..117300e2 100644 --- a/doc/models/update-shift-response.md +++ b/doc/models/update-shift-response.md @@ -33,6 +33,10 @@ the request resulted in errors. } ], "created_at": "2019-02-28T00:39:02Z", + "declared_cash_tip_money": { + "amount": 500, + "currency": "USD" + }, "employee_id": "ormj0jJJZ5OZIzxrZYJI", "end_at": "2019-01-25T13:11:00-05:00", "id": "K0YH4CV5462JB", @@ -49,6 +53,7 @@ the request resulted in errors. "currency": "USD" }, "job_id": "dZtrPh5GSDGugyXGByesVp51", + "tip_eligible": true, "title": "Bartender" } }, diff --git a/pyproject.toml b/pyproject.toml index e25c88c5..578c94ac 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ requires = ["setuptools>=61.0"] [project] name = "squareup" description = "Use Square APIs to manage and run business including payment, customer, product, inventory, and employee management." -version = "32.0.0.20231018" +version = "33.0.0.20231115" readme = "README.md" requires-python = ">=3.7" authors = [{name = "Square Developer Platform", email = "developers@squareup.com"}] diff --git a/square/api/base_api.py b/square/api/base_api.py index f738e006..a56d05c1 100644 --- a/square/api/base_api.py +++ b/square/api/base_api.py @@ -23,7 +23,7 @@ class BaseApi(object): @staticmethod def user_agent(): - return 'Square-Python-SDK/32.0.0.20231018 ({api-version}) {engine}/{engine-version} ({os-info}) {detail}' + return 'Square-Python-SDK/33.0.0.20231115 ({api-version}) {engine}/{engine-version} ({os-info}) {detail}' @staticmethod def user_agent_parameters(): diff --git a/square/client.py b/square/client.py index f4ec0fd7..e91f14fd 100644 --- a/square/client.py +++ b/square/client.py @@ -55,11 +55,11 @@ class Client(object): @staticmethod def sdk_version(): - return '32.0.0.20231018' + return '33.0.0.20231115' @staticmethod def square_version(): - return '2023-10-18' + return '2023-11-15' def user_agent_detail(self): return self.config.user_agent_detail @@ -234,7 +234,7 @@ def __init__(self, http_client_instance=None, retry_statuses=[408, 413, 429, 500, 502, 503, 504, 521, 522, 524], retry_methods=['GET', 'PUT'], environment='production', custom_url='https://connect.squareup.com', access_token='', - square_version='2023-10-18', additional_headers={}, + square_version='2023-11-15', additional_headers={}, user_agent_detail='', config=None): if config is None: self.config = Configuration( diff --git a/square/configuration.py b/square/configuration.py index 237ee7e3..b217b314 100644 --- a/square/configuration.py +++ b/square/configuration.py @@ -41,7 +41,7 @@ def __init__( retry_statuses=[408, 413, 429, 500, 502, 503, 504, 521, 522, 524], retry_methods=['GET', 'PUT'], environment='production', custom_url='https://connect.squareup.com', access_token='', - square_version='2023-10-18', additional_headers={}, + square_version='2023-11-15', additional_headers={}, user_agent_detail='' ): super().__init__(http_client_instance, override_http_client_configuration, http_call_back, timeout, max_retries,