Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🌿 Fern Regeneration -- April 4, 2025 #149

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
93 changes: 93 additions & 0 deletions .mock/definition/__package__.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3378,6 +3378,38 @@ types:
from the `amount_money` and `buyer_supplied_money` fields.
source:
openapi: openapi/openapi.json
CatalogAvailabilityPeriod:
docs: Represents a time period of availability.
properties:
start_local_time:
type: optional<nullable<string>>
docs: >-
The start time of an availability period, specified in local time
using partial-time

RFC 3339 format. For example, `8:30:00` for a period starting at 8:30
in the morning.

Note that the seconds value is always :00, but it is appended for
conformance to the RFC.
end_local_time:
type: optional<nullable<string>>
docs: >-
The end time of an availability period, specified in local time using
partial-time

RFC 3339 format. For example, `21:00:00` for a period ending at 9:00
in the evening.

Note that the seconds value is always :00, but it is appended for
conformance to the RFC.
day_of_week:
type: optional<DayOfWeek>
docs: |-
The day of the week for this availability period.
See [DayOfWeek](#type-dayofweek) for possible values
source:
openapi: openapi/openapi.json
CatalogCategory:
docs: A category to which a `CatalogItem` instance belongs.
properties:
Expand Down Expand Up @@ -5129,6 +5161,8 @@ types:
CHECKOUT_LINK: CatalogObjectCheckoutLink
ADDRESS: CatalogObjectAddress
SUBSCRIPTION_PRODUCT: CatalogObjectSubscriptionProduct
SUBSCRIPTION_PLAN_VARIATION: CatalogObjectSubscriptionPlanVariation
AVAILABILITY_PERIOD: CatalogObjectAvailabilityPeriod
source:
openapi: openapi/openapi.json
CatalogObjectBatch:
Expand Down Expand Up @@ -6156,6 +6190,43 @@ types:
SubscriptionPlan.
source:
openapi: openapi/openapi.json
CatalogSubscriptionPlanVariation:
docs: >-
Describes a subscription plan variation. A subscription plan variation
represents how the subscription for a product or service is sold.

For more information, see [Subscription Plans and
Variations](https://developer.squareup.com/docs/subscriptions-api/plans-and-variations).
properties:
name:
type: string
docs: The name of the plan variation.
phases:
docs: >-
A list containing each [SubscriptionPhase](entity:SubscriptionPhase)
for this plan variation.
type: list<SubscriptionPhase>
subscription_plan_id:
type: optional<nullable<string>>
docs: The id of the subscription plan, if there is one.
monthly_billing_anchor_date:
type: optional<nullable<long>>
docs: The day of the month the billing period starts.
can_prorate:
type: optional<nullable<boolean>>
docs: Whether bills for this plan variation can be split for proration.
successor_plan_variation_id:
type: optional<nullable<string>>
docs: >-
The ID of a "successor" plan variation to this one. If the field is
set, and this object is disabled at all

locations, it indicates that this variation is deprecated and the
object identified by the successor ID be used in

its stead.
source:
openapi: openapi/openapi.json
CatalogTax:
docs: A tax applicable to an item.
properties:
Expand Down Expand Up @@ -26939,6 +27010,28 @@ types:
- CatalogObjectBase
source:
openapi: openapi/openapi.json
CatalogObjectSubscriptionPlanVariation:
properties:
subscription_plan_variation_data:
type: optional<CatalogSubscriptionPlanVariation>
docs: >-
Structured data for a `CatalogSubscriptionPlanVariation`, set for
CatalogObjects of type `SUBSCRIPTION_PLAN_VARIATION`.
extends:
- CatalogObjectBase
source:
openapi: openapi/openapi.json
CatalogObjectAvailabilityPeriod:
properties:
availability_period_data:
type: optional<CatalogAvailabilityPeriod>
docs: >-
Structured data for a `CatalogAvailabilityPeriod`, set for
CatalogObjects of type `AVAILABILITY_PERIOD`.
extends:
- CatalogObjectBase
source:
openapi: openapi/openapi.json
CatalogObjectComponent:
properties: {}
extends:
Expand Down
2 changes: 1 addition & 1 deletion .mock/fern.config.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"organization" : "square",
"version" : "0.56.24"
"version" : "0.57.11"
}
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "square/square",
"version": "42.0.0.20250319",
"version": "42.0.1.20250319",
"description": "Use Square APIs to manage and run business including payment, customer, product, inventory, and employee management.",
"keywords": [
"square",
Expand Down
4 changes: 2 additions & 2 deletions src/SquareClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -250,8 +250,8 @@ public function __construct(
'Square-Version' => '2025-03-19',
'X-Fern-Language' => 'PHP',
'X-Fern-SDK-Name' => 'Square',
'X-Fern-SDK-Version' => '42.0.0.20250319',
'User-Agent' => 'square/square/42.0.0.20250319',
'X-Fern-SDK-Version' => '42.0.1.20250319',
'User-Agent' => 'square/square/42.0.1.20250319',
];
if ($version != null) {
$defaultHeaders['Square-Version'] = $version;
Expand Down
115 changes: 115 additions & 0 deletions src/Types/CatalogAvailabilityPeriod.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
<?php

namespace Square\Types;

use Square\Core\Json\JsonSerializableType;
use Square\Core\Json\JsonProperty;

/**
* Represents a time period of availability.
*/
class CatalogAvailabilityPeriod extends JsonSerializableType
{
/**
* The start time of an availability period, specified in local time using partial-time
* RFC 3339 format. For example, `8:30:00` for a period starting at 8:30 in the morning.
* Note that the seconds value is always :00, but it is appended for conformance to the RFC.
*
* @var ?string $startLocalTime
*/
#[JsonProperty('start_local_time')]
private ?string $startLocalTime;

/**
* The end time of an availability period, specified in local time using partial-time
* RFC 3339 format. For example, `21:00:00` for a period ending at 9:00 in the evening.
* Note that the seconds value is always :00, but it is appended for conformance to the RFC.
*
* @var ?string $endLocalTime
*/
#[JsonProperty('end_local_time')]
private ?string $endLocalTime;

/**
* The day of the week for this availability period.
* See [DayOfWeek](#type-dayofweek) for possible values
*
* @var ?value-of<DayOfWeek> $dayOfWeek
*/
#[JsonProperty('day_of_week')]
private ?string $dayOfWeek;

/**
* @param array{
* startLocalTime?: ?string,
* endLocalTime?: ?string,
* dayOfWeek?: ?value-of<DayOfWeek>,
* } $values
*/
public function __construct(
array $values = [],
) {
$this->startLocalTime = $values['startLocalTime'] ?? null;
$this->endLocalTime = $values['endLocalTime'] ?? null;
$this->dayOfWeek = $values['dayOfWeek'] ?? null;
}

/**
* @return ?string
*/
public function getStartLocalTime(): ?string
{
return $this->startLocalTime;
}

/**
* @param ?string $value
*/
public function setStartLocalTime(?string $value = null): self
{
$this->startLocalTime = $value;
return $this;
}

/**
* @return ?string
*/
public function getEndLocalTime(): ?string
{
return $this->endLocalTime;
}

/**
* @param ?string $value
*/
public function setEndLocalTime(?string $value = null): self
{
$this->endLocalTime = $value;
return $this;
}

/**
* @return ?value-of<DayOfWeek>
*/
public function getDayOfWeek(): ?string
{
return $this->dayOfWeek;
}

/**
* @param ?value-of<DayOfWeek> $value
*/
public function setDayOfWeek(?string $value = null): self
{
$this->dayOfWeek = $value;
return $this;
}

/**
* @return string
*/
public function __toString(): string
{
return $this->toJson();
}
}
Loading