diff --git a/.fern/metadata.json b/.fern/metadata.json
index a3c7dd0d..7c1189c2 100644
--- a/.fern/metadata.json
+++ b/.fern/metadata.json
@@ -23,6 +23,6 @@
}
}
},
- "originGitCommit": "b05364cda2b85e35d8daa9ff2c24bbabbbd9652a",
- "sdkVersion": "46.1.0.20260819"
+ "originGitCommit": "f74d4b7e34b9b8676dc4b58d83a38111dc1d595f",
+ "sdkVersion": "47.0.0.20260916"
}
\ No newline at end of file
diff --git a/.fern/replay.lock b/.fern/replay.lock
index 6f61273f..2f69f97c 100644
--- a/.fern/replay.lock
+++ b/.fern/replay.lock
@@ -24,5 +24,11 @@ generations:
cli_version: unknown
generator_versions:
fernapi/fern-php-sdk: 2.1.5
-current_generation: 0ba6f5e051ee942bbefed88fff34a9f2522db25b
+ - commit_sha: d18d740da547dcc3cecbc5eedf95ce9e1b07387d
+ tree_hash: 07fdf09287190f8174ee19f351f54cf132e92595
+ timestamp: 2026-09-15T18:44:04.667Z
+ cli_version: unknown
+ generator_versions:
+ fernapi/fern-php-sdk: 2.1.5
+current_generation: d18d740da547dcc3cecbc5eedf95ce9e1b07387d
patches: []
diff --git a/composer.json b/composer.json
index a0fd398b..a54f6ee9 100644
--- a/composer.json
+++ b/composer.json
@@ -1,6 +1,6 @@
{
"name": "square/square",
- "version": "46.1.0.20260819",
+ "version": "47.0.0.20260916",
"description": "Use Square APIs to manage and run business including payment, customer, product, inventory, and employee management.",
"keywords": [
"square",
diff --git a/reference.md b/reference.md
index caf9f473..ec090e35 100644
--- a/reference.md
+++ b/reference.md
@@ -7388,50 +7388,6 @@ See the [Pagination](https://developer.squareup.com/docs/working-with-apis/pagin
-
-
-
-
-$client->inventory->getTransfer($request)
-
--
-
-#### 🔌 Usage
-
-
--
-
-
--
-
-```php
-$client->inventory->getTransfer(
- new GetTransferInventoryRequest([
- 'transferId' => 'transfer_id',
- ]),
-);
-```
-
-
-
-
-
-#### ⚙️ Parameters
-
-
--
-
-
--
-
-**$transferId:** `string`
-
-
-
-
-
-
-
@@ -23647,150 +23603,6 @@ $client->locations->transactions->get(
-
-
-
-
-$client->locations->transactions->capture($request) -> CaptureTransactionResponse
-
--
-
-#### 📝 Description
-
-
--
-
-
--
-
-Captures a transaction that was created with the [Charge](api-endpoint:Transactions-Charge)
-endpoint with a `delay_capture` value of `true`.
-
-
-See [Delayed capture transactions](https://developer.squareup.com/docs/payments/transactions/overview#delayed-capture)
-for more information.
-
-
-
-
-
-#### 🔌 Usage
-
-
--
-
-
--
-
-```php
-$client->locations->transactions->capture(
- new CaptureTransactionsRequest([
- 'locationId' => 'location_id',
- 'transactionId' => 'transaction_id',
- ]),
-);
-```
-
-
-
-
-
-#### ⚙️ Parameters
-
-
--
-
-
--
-
-**$locationId:** `string` —
-
-
-
-
-
--
-
-**$transactionId:** `string` —
-
-
-
-
-
-
-
-
-
-
-
-$client->locations->transactions->void($request) -> VoidTransactionResponse
-
--
-
-#### 📝 Description
-
-
--
-
-
--
-
-Cancels a transaction that was created with the [Charge](api-endpoint:Transactions-Charge)
-endpoint with a `delay_capture` value of `true`.
-
-
-See [Delayed capture transactions](https://developer.squareup.com/docs/payments/transactions/overview#delayed-capture)
-for more information.
-
-
-
-
-
-#### 🔌 Usage
-
-
--
-
-
--
-
-```php
-$client->locations->transactions->void(
- new VoidTransactionsRequest([
- 'locationId' => 'location_id',
- 'transactionId' => 'transaction_id',
- ]),
-);
-```
-
-
-
-
-
-#### ⚙️ Parameters
-
-
--
-
-
--
-
-**$locationId:** `string` —
-
-
-
-
-
--
-
-**$transactionId:** `string` —
-
-
-
-
-
-
-
diff --git a/src/Inventory/InventoryClient.php b/src/Inventory/InventoryClient.php
index 9cabce1f..c74c9e77 100644
--- a/src/Inventory/InventoryClient.php
+++ b/src/Inventory/InventoryClient.php
@@ -45,7 +45,6 @@
use Square\Types\GetInventoryCountResponse;
use Square\Inventory\Requests\ChangesInventoryRequest;
use Square\Types\GetInventoryChangesResponse;
-use Square\Inventory\Requests\GetTransferInventoryRequest;
class InventoryClient
{
@@ -940,45 +939,6 @@ public function changes(ChangesInventoryRequest $request, ?array $options = null
);
}
- /**
- * @param GetTransferInventoryRequest $request
- * @param ?array{
- * baseUrl?: string,
- * maxRetries?: int,
- * timeout?: float,
- * headers?: array,
- * queryParameters?: array,
- * bodyProperties?: array,
- * } $options
- * @throws SquareException
- * @throws SquareApiException
- */
- public function getTransfer(GetTransferInventoryRequest $request, ?array $options = null): void
- {
- $options = array_merge($this->options, $options ?? []);
- try {
- $response = $this->client->sendRequest(
- new JsonApiRequest(
- baseUrl: $options['baseUrl'] ?? $this->client->options['baseUrl'] ?? Environments::Production->value,
- path: "v2/inventory/transfers/{$request->getTransferId()}",
- method: HttpMethod::GET,
- ),
- $options,
- );
- $statusCode = $response->getStatusCode();
- if ($statusCode >= 200 && $statusCode < 400) {
- return;
- }
- } catch (ClientExceptionInterface $e) {
- throw new SquareException(message: $e->getMessage(), previous: $e);
- }
- throw new SquareApiException(
- message: 'API request failed',
- statusCode: $statusCode,
- body: $response->getBody()->getContents(),
- );
- }
-
/**
* Returns historical physical counts and adjustments based on the
* provided filter criteria.
diff --git a/src/Inventory/Requests/GetTransferInventoryRequest.php b/src/Inventory/Requests/GetTransferInventoryRequest.php
deleted file mode 100644
index 9fece810..00000000
--- a/src/Inventory/Requests/GetTransferInventoryRequest.php
+++ /dev/null
@@ -1,42 +0,0 @@
-transferId = $values['transferId'];
- }
-
- /**
- * @return string
- */
- public function getTransferId(): string
- {
- return $this->transferId;
- }
-
- /**
- * @param string $value
- */
- public function setTransferId(string $value): self
- {
- $this->transferId = $value;
- $this->_setField('transferId');
- return $this;
- }
-}
diff --git a/src/Locations/Transactions/Requests/CaptureTransactionsRequest.php b/src/Locations/Transactions/Requests/CaptureTransactionsRequest.php
deleted file mode 100644
index 32d19c46..00000000
--- a/src/Locations/Transactions/Requests/CaptureTransactionsRequest.php
+++ /dev/null
@@ -1,67 +0,0 @@
-locationId = $values['locationId'];
- $this->transactionId = $values['transactionId'];
- }
-
- /**
- * @return string
- */
- public function getLocationId(): string
- {
- return $this->locationId;
- }
-
- /**
- * @param string $value
- */
- public function setLocationId(string $value): self
- {
- $this->locationId = $value;
- $this->_setField('locationId');
- return $this;
- }
-
- /**
- * @return string
- */
- public function getTransactionId(): string
- {
- return $this->transactionId;
- }
-
- /**
- * @param string $value
- */
- public function setTransactionId(string $value): self
- {
- $this->transactionId = $value;
- $this->_setField('transactionId');
- return $this;
- }
-}
diff --git a/src/Locations/Transactions/Requests/VoidTransactionsRequest.php b/src/Locations/Transactions/Requests/VoidTransactionsRequest.php
deleted file mode 100644
index 68848afe..00000000
--- a/src/Locations/Transactions/Requests/VoidTransactionsRequest.php
+++ /dev/null
@@ -1,67 +0,0 @@
-locationId = $values['locationId'];
- $this->transactionId = $values['transactionId'];
- }
-
- /**
- * @return string
- */
- public function getLocationId(): string
- {
- return $this->locationId;
- }
-
- /**
- * @param string $value
- */
- public function setLocationId(string $value): self
- {
- $this->locationId = $value;
- $this->_setField('locationId');
- return $this;
- }
-
- /**
- * @return string
- */
- public function getTransactionId(): string
- {
- return $this->transactionId;
- }
-
- /**
- * @param string $value
- */
- public function setTransactionId(string $value): self
- {
- $this->transactionId = $value;
- $this->_setField('transactionId');
- return $this;
- }
-}
diff --git a/src/Locations/Transactions/TransactionsClient.php b/src/Locations/Transactions/TransactionsClient.php
index 4a239d4a..0a9f3e37 100644
--- a/src/Locations/Transactions/TransactionsClient.php
+++ b/src/Locations/Transactions/TransactionsClient.php
@@ -15,10 +15,6 @@
use Psr\Http\Client\ClientExceptionInterface;
use Square\Locations\Transactions\Requests\GetTransactionsRequest;
use Square\Types\GetTransactionResponse;
-use Square\Locations\Transactions\Requests\CaptureTransactionsRequest;
-use Square\Types\CaptureTransactionResponse;
-use Square\Locations\Transactions\Requests\VoidTransactionsRequest;
-use Square\Types\VoidTransactionResponse;
class TransactionsClient
{
@@ -164,104 +160,4 @@ public function get(GetTransactionsRequest $request, ?array $options = null): Ge
body: $response->getBody()->getContents(),
);
}
-
- /**
- * Captures a transaction that was created with the [Charge](api-endpoint:Transactions-Charge)
- * endpoint with a `delay_capture` value of `true`.
- *
- *
- * See [Delayed capture transactions](https://developer.squareup.com/docs/payments/transactions/overview#delayed-capture)
- * for more information.
- *
- * @param CaptureTransactionsRequest $request
- * @param ?array{
- * baseUrl?: string,
- * maxRetries?: int,
- * timeout?: float,
- * headers?: array,
- * queryParameters?: array,
- * bodyProperties?: array,
- * } $options
- * @return CaptureTransactionResponse
- * @throws SquareException
- * @throws SquareApiException
- */
- public function capture(CaptureTransactionsRequest $request, ?array $options = null): CaptureTransactionResponse
- {
- $options = array_merge($this->options, $options ?? []);
- try {
- $response = $this->client->sendRequest(
- new JsonApiRequest(
- baseUrl: $options['baseUrl'] ?? $this->client->options['baseUrl'] ?? Environments::Production->value,
- path: "v2/locations/{$request->getLocationId()}/transactions/{$request->getTransactionId()}/capture",
- method: HttpMethod::POST,
- ),
- $options,
- );
- $statusCode = $response->getStatusCode();
- if ($statusCode >= 200 && $statusCode < 400) {
- $json = $response->getBody()->getContents();
- return CaptureTransactionResponse::fromJson($json);
- }
- } catch (JsonException $e) {
- throw new SquareException(message: "Failed to deserialize response: {$e->getMessage()}", previous: $e);
- } catch (ClientExceptionInterface $e) {
- throw new SquareException(message: $e->getMessage(), previous: $e);
- }
- throw new SquareApiException(
- message: 'API request failed',
- statusCode: $statusCode,
- body: $response->getBody()->getContents(),
- );
- }
-
- /**
- * Cancels a transaction that was created with the [Charge](api-endpoint:Transactions-Charge)
- * endpoint with a `delay_capture` value of `true`.
- *
- *
- * See [Delayed capture transactions](https://developer.squareup.com/docs/payments/transactions/overview#delayed-capture)
- * for more information.
- *
- * @param VoidTransactionsRequest $request
- * @param ?array{
- * baseUrl?: string,
- * maxRetries?: int,
- * timeout?: float,
- * headers?: array,
- * queryParameters?: array,
- * bodyProperties?: array,
- * } $options
- * @return VoidTransactionResponse
- * @throws SquareException
- * @throws SquareApiException
- */
- public function void(VoidTransactionsRequest $request, ?array $options = null): VoidTransactionResponse
- {
- $options = array_merge($this->options, $options ?? []);
- try {
- $response = $this->client->sendRequest(
- new JsonApiRequest(
- baseUrl: $options['baseUrl'] ?? $this->client->options['baseUrl'] ?? Environments::Production->value,
- path: "v2/locations/{$request->getLocationId()}/transactions/{$request->getTransactionId()}/void",
- method: HttpMethod::POST,
- ),
- $options,
- );
- $statusCode = $response->getStatusCode();
- if ($statusCode >= 200 && $statusCode < 400) {
- $json = $response->getBody()->getContents();
- return VoidTransactionResponse::fromJson($json);
- }
- } catch (JsonException $e) {
- throw new SquareException(message: "Failed to deserialize response: {$e->getMessage()}", previous: $e);
- } catch (ClientExceptionInterface $e) {
- throw new SquareException(message: $e->getMessage(), previous: $e);
- }
- throw new SquareApiException(
- message: 'API request failed',
- statusCode: $statusCode,
- body: $response->getBody()->getContents(),
- );
- }
}
diff --git a/src/SquareClient.php b/src/SquareClient.php
index 20887527..85d35458 100644
--- a/src/SquareClient.php
+++ b/src/SquareClient.php
@@ -259,11 +259,11 @@ public function __construct(
$token ??= $this->getFromEnvOrThrow('SQUARE_TOKEN', 'Please pass in token or set the environment variable SQUARE_TOKEN.');
$defaultHeaders = [
'Authorization' => "Bearer $token",
- 'Square-Version' => '2026-08-19',
+ 'Square-Version' => '2026-09-16',
'X-Fern-Language' => 'PHP',
'X-Fern-SDK-Name' => 'Square',
- 'X-Fern-SDK-Version' => '46.1.0.20260819',
- 'User-Agent' => 'square/square/46.1.0.20260819',
+ 'X-Fern-SDK-Version' => '47.0.0.20260916',
+ 'User-Agent' => 'square/square/47.0.0.20260916',
];
if ($version != null) {
$defaultHeaders['Square-Version'] = $version;
diff --git a/src/Types/CaptureTransactionResponse.php b/src/Types/CaptureTransactionResponse.php
deleted file mode 100644
index 99ac3d08..00000000
--- a/src/Types/CaptureTransactionResponse.php
+++ /dev/null
@@ -1,57 +0,0 @@
- $errors Any errors that occurred during the request.
- */
- #[JsonProperty('errors'), ArrayType([Error::class])]
- private ?array $errors;
-
- /**
- * @param array{
- * errors?: ?array,
- * } $values
- */
- public function __construct(
- array $values = [],
- ) {
- $this->errors = $values['errors'] ?? null;
- }
-
- /**
- * @return ?array
- */
- public function getErrors(): ?array
- {
- return $this->errors;
- }
-
- /**
- * @param ?array $value
- */
- public function setErrors(?array $value = null): self
- {
- $this->errors = $value;
- $this->_setField('errors');
- return $this;
- }
-
- /**
- * @return string
- */
- public function __toString(): string
- {
- return $this->toJson();
- }
-}
diff --git a/src/Types/VoidTransactionResponse.php b/src/Types/VoidTransactionResponse.php
deleted file mode 100644
index ef64e849..00000000
--- a/src/Types/VoidTransactionResponse.php
+++ /dev/null
@@ -1,57 +0,0 @@
- $errors Any errors that occurred during the request.
- */
- #[JsonProperty('errors'), ArrayType([Error::class])]
- private ?array $errors;
-
- /**
- * @param array{
- * errors?: ?array,
- * } $values
- */
- public function __construct(
- array $values = [],
- ) {
- $this->errors = $values['errors'] ?? null;
- }
-
- /**
- * @return ?array
- */
- public function getErrors(): ?array
- {
- return $this->errors;
- }
-
- /**
- * @param ?array $value
- */
- public function setErrors(?array $value = null): self
- {
- $this->errors = $value;
- $this->_setField('errors');
- return $this;
- }
-
- /**
- * @return string
- */
- public function __toString(): string
- {
- return $this->toJson();
- }
-}