Skip to content

Commit

Permalink
Merge pull request #69 from dubinc/speakeasy-sdk-regen-1737073161
Browse files Browse the repository at this point in the history
chore: 🐝 Update SDK - Generate 0.11.16
  • Loading branch information
devkiran authored Jan 17, 2025
2 parents 856853a + 8774a9a commit bdde09e
Show file tree
Hide file tree
Showing 26 changed files with 336 additions and 64 deletions.
25 changes: 18 additions & 7 deletions .speakeasy/gen.lock
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
lockVersion: 2.0.0
id: 43187d3e-7c3c-4c11-b5d4-4b2334fb6d96
management:
docChecksum: 810d019618d329428080463b7bf165c7
docChecksum: c7226fc27f4fb4b6c492bc7d8bb0ce6d
docVersion: 0.0.1
speakeasyVersion: 1.468.6
generationVersion: 2.493.13
releaseVersion: 0.11.15
configChecksum: adde5023a17aa572053f9421707ab5d0
speakeasyVersion: 1.468.9
generationVersion: 2.493.21
releaseVersion: 0.11.16
configChecksum: aaa0dc1fbd29c009e7f1bcb8a4d18cfa
repoURL: https://github.com/dubinc/dub-php.git
installationURL: https://github.com/dubinc/dub-php
published: true
features:
php:
constsAndDefaults: 0.2.0
core: 3.7.8
core: 3.7.9
deprecations: 2.81.1
errors: 0.3.0
examples: 2.81.4
examples: 2.81.5
flattening: 2.81.1
globalSecurity: 2.81.7
globalSecurityFlattening: 0.1.1
Expand Down Expand Up @@ -208,10 +208,14 @@ generatedFiles:
- docs/Models/Operations/GetMetatagsResponseBody.md
- docs/Models/Operations/GetQRCodeRequest.md
- docs/Models/Operations/GetQRCodeResponse.md
- docs/Models/Operations/GetTagsQueryParamSortBy.md
- docs/Models/Operations/GetTagsQueryParamSortOrder.md
- docs/Models/Operations/GetTagsRequest.md
- docs/Models/Operations/GetTagsResponse.md
- docs/Models/Operations/GetWorkspaceRequest.md
- docs/Models/Operations/GetWorkspaceResponse.md
- docs/Models/Operations/GroupBy.md
- docs/Models/Operations/Ids.md
- docs/Models/Operations/Interval.md
- docs/Models/Operations/Level.md
- docs/Models/Operations/Link.md
Expand Down Expand Up @@ -502,6 +506,9 @@ generatedFiles:
- src/Models/Operations/GetMetatagsResponseBody.php
- src/Models/Operations/GetQRCodeRequest.php
- src/Models/Operations/GetQRCodeResponse.php
- src/Models/Operations/GetTagsQueryParamSortBy.php
- src/Models/Operations/GetTagsQueryParamSortOrder.php
- src/Models/Operations/GetTagsRequest.php
- src/Models/Operations/GetTagsResponse.php
- src/Models/Operations/GetWorkspaceRequest.php
- src/Models/Operations/GetWorkspaceResponse.php
Expand Down Expand Up @@ -1006,6 +1013,10 @@ examples:
application/json: {"error": {"code": "internal_server_error", "message": "The requested resource was not found.", "doc_url": "https://dub.co/docs/api-reference/errors#internal-server_error"}}
getTags:
speakeasy-default-get-tags:
parameters:
query:
page: 1
pageSize: 50
responses:
"400":
application/json: {"error": {"code": "bad_request", "message": "The requested resource was not found.", "doc_url": "https://dub.co/docs/api-reference/errors#bad-request"}}
Expand Down
2 changes: 1 addition & 1 deletion .speakeasy/gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ generation:
oAuth2ClientCredentialsEnabled: true
oAuth2PasswordEnabled: false
php:
version: 0.11.15
version: 0.11.16
additionalDependencies:
autoload: {}
autoload-dev: {}
Expand Down
14 changes: 7 additions & 7 deletions .speakeasy/workflow.lock
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
speakeasyVersion: 1.468.6
speakeasyVersion: 1.468.9
sources:
dub:
sourceNamespace: dub
sourceRevisionDigest: sha256:fc9723fc3c7681f38d2b7ff1d4ff2d0e515481d1b41c26aa81e3c00f5175d98a
sourceBlobDigest: sha256:4f857c24e9fc5883500df254e0cfeda49c2c1251bcc40597d9751bd2f79fc07d
sourceRevisionDigest: sha256:7b9e196d66f3163418a4e27322e3c6de647189ffeba069d657bd4230a9f2aa92
sourceBlobDigest: sha256:3b9749ee4775b8022360e4efaad2a707cd10b0d65d85a424cb17498b6d1e6005
tags:
- latest
- speakeasy-sdk-regen-1736900362
- speakeasy-sdk-regen-1737073161
- 0.0.1
targets:
my-first-target:
source: dub
sourceNamespace: dub
sourceRevisionDigest: sha256:fc9723fc3c7681f38d2b7ff1d4ff2d0e515481d1b41c26aa81e3c00f5175d98a
sourceBlobDigest: sha256:4f857c24e9fc5883500df254e0cfeda49c2c1251bcc40597d9751bd2f79fc07d
sourceRevisionDigest: sha256:7b9e196d66f3163418a4e27322e3c6de647189ffeba069d657bd4230a9f2aa92
sourceBlobDigest: sha256:3b9749ee4775b8022360e4efaad2a707cd10b0d65d85a424cb17498b6d1e6005
codeSamplesNamespace: code-samples-php-my-first-target
codeSamplesRevisionDigest: sha256:ff0794c6f7d1fc447e882b7bea7879103a52ad0aed9b103c519b89081659dd1c
codeSamplesRevisionDigest: sha256:3a9bee719bbfe7adec461520505ffef25cce945a3484ed32fc33be0e4956f714
workflow:
workflowVersion: 1.0.0
speakeasyVersion: latest
Expand Down
12 changes: 11 additions & 1 deletion RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -600,4 +600,14 @@ Based on:
### Generated
- [php v0.11.15] .
### Releases
- [Composer v0.11.15] https://packagist.org/packages/dub/dub-php#v0.11.15 - .
- [Composer v0.11.15] https://packagist.org/packages/dub/dub-php#v0.11.15 - .

## 2025-01-17 00:19:05
### Changes
Based on:
- OpenAPI Doc
- Speakeasy CLI 1.468.9 (2.493.21) https://github.com/speakeasy-api/speakeasy
### Generated
- [php v0.11.16] .
### Releases
- [Composer v0.11.16] https://packagist.org/packages/dub/dub-php#v0.11.16 - .
2 changes: 1 addition & 1 deletion codeSamples.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ actions:
"x-codeSamples":
- "lang": "php"
"label": "getTags"
"source": "declare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Dub;\n\n$sdk = Dub\\Dub::builder()\n ->setSecurity(\n 'DUB_API_KEY'\n )\n ->build();\n\n\n\n$response = $sdk->tags->list(\n\n);\n\nif ($response->tagSchemas !== null) {\n // handle response\n}"
"source": "declare(strict_types=1);\n\nrequire 'vendor/autoload.php';\n\nuse Dub;\nuse Dub\\Models\\Operations;\n\n$sdk = Dub\\Dub::builder()\n ->setSecurity(\n 'DUB_API_KEY'\n )\n ->build();\n\n$request = new Operations\\GetTagsRequest(\n page: 1,\n pageSize: 50,\n);\n\n$response = $sdk->tags->list(\n request: $request\n);\n\nif ($response->tagSchemas !== null) {\n // handle response\n}"
- target: $["paths"]["/tags"]["post"]
update:
"x-codeSamples":
Expand Down
11 changes: 11 additions & 0 deletions docs/Models/Operations/GetTagsQueryParamSortBy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# GetTagsQueryParamSortBy

The field to sort the tags by.


## Values

| Name | Value |
| ----------- | ----------- |
| `Name` | name |
| `CreatedAt` | createdAt |
11 changes: 11 additions & 0 deletions docs/Models/Operations/GetTagsQueryParamSortOrder.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# GetTagsQueryParamSortOrder

The order to sort the tags by.


## Values

| Name | Value |
| ------ | ------ |
| `Asc` | asc |
| `Desc` | desc |
13 changes: 13 additions & 0 deletions docs/Models/Operations/GetTagsRequest.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# GetTagsRequest


## Fields

| Field | Type | Required | Description | Example |
| ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- |
| `sortBy` | [?Operations\GetTagsQueryParamSortBy](../../Models/Operations/GetTagsQueryParamSortBy.md) | :heavy_minus_sign: | The field to sort the tags by. | |
| `sortOrder` | [?Operations\GetTagsQueryParamSortOrder](../../Models/Operations/GetTagsQueryParamSortOrder.md) | :heavy_minus_sign: | The order to sort the tags by. | |
| `search` | *?string* | :heavy_minus_sign: | The search term to filter the tags by. | |
| `ids` | [string\|array\|null](../../Models/Operations/Ids.md) | :heavy_minus_sign: | IDs of tags to filter by. | |
| `page` | *?float* | :heavy_minus_sign: | The page number for pagination. | 1 |
| `pageSize` | *?float* | :heavy_minus_sign: | The number of items per page. | 50 |
25 changes: 25 additions & 0 deletions docs/Models/Operations/Ids.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Ids

IDs of tags to filter by.


## Supported Types

### `string`

```php
/**
* @var string
*/
string $value = /* values here */
```

### `array`

```php
/**
* @var array<string>
*/
array $value = /* values here */
```

14 changes: 12 additions & 2 deletions docs/sdks/tags/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,24 +133,34 @@ declare(strict_types=1);
require 'vendor/autoload.php';

use Dub;
use Dub\Models\Operations;

$sdk = Dub\Dub::builder()
->setSecurity(
'DUB_API_KEY'
)
->build();


$request = new Operations\GetTagsRequest(
page: 1,
pageSize: 50,
);

$response = $sdk->tags->list(

request: $request
);

if ($response->tagSchemas !== null) {
// handle response
}
```

### Parameters

| Parameter | Type | Required | Description |
| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- |
| `$request` | [Operations\GetTagsRequest](../../Models/Operations/GetTagsRequest.md) | :heavy_check_mark: | The request object to use for the request. |

### Response

**[?Operations\GetTagsResponse](../../Models/Operations/GetTagsResponse.md)**
Expand Down
4 changes: 3 additions & 1 deletion src/Analytics.php
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,9 @@ public function retrieve(?Operations\RetrieveAnalyticsRequest $request = null, ?
} else {
throw new \Dub\Models\Errors\SDKException('Unknown content type received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
}
} elseif ($statusCode >= 400 && $statusCode < 500 || $statusCode >= 500 && $statusCode < 600) {
} elseif ($statusCode >= 400 && $statusCode < 500) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} elseif ($statusCode >= 500 && $statusCode < 600) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} else {
throw new \Dub\Models\Errors\SDKException('Unknown status code received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
Expand Down
20 changes: 15 additions & 5 deletions src/Customers.php
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,9 @@ public function create(?Operations\CreateCustomerRequestBody $request = null, ?O
} else {
throw new \Dub\Models\Errors\SDKException('Unknown content type received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
}
} elseif ($statusCode >= 400 && $statusCode < 500 || $statusCode >= 500 && $statusCode < 600) {
} elseif ($statusCode >= 400 && $statusCode < 500) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} elseif ($statusCode >= 500 && $statusCode < 600) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} else {
throw new \Dub\Models\Errors\SDKException('Unknown status code received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
Expand Down Expand Up @@ -360,7 +362,9 @@ public function delete(string $id, ?Options $options = null): Operations\DeleteC
} else {
throw new \Dub\Models\Errors\SDKException('Unknown content type received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
}
} elseif ($statusCode >= 400 && $statusCode < 500 || $statusCode >= 500 && $statusCode < 600) {
} elseif ($statusCode >= 400 && $statusCode < 500) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} elseif ($statusCode >= 500 && $statusCode < 600) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} else {
throw new \Dub\Models\Errors\SDKException('Unknown status code received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
Expand Down Expand Up @@ -526,7 +530,9 @@ public function get(string $id, ?bool $includeExpandedFields = null, ?Options $o
} else {
throw new \Dub\Models\Errors\SDKException('Unknown content type received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
}
} elseif ($statusCode >= 400 && $statusCode < 500 || $statusCode >= 500 && $statusCode < 600) {
} elseif ($statusCode >= 400 && $statusCode < 500) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} elseif ($statusCode >= 500 && $statusCode < 600) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} else {
throw new \Dub\Models\Errors\SDKException('Unknown status code received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
Expand Down Expand Up @@ -694,7 +700,9 @@ public function list(?string $email = null, ?string $externalId = null, ?bool $i
} else {
throw new \Dub\Models\Errors\SDKException('Unknown content type received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
}
} elseif ($statusCode >= 400 && $statusCode < 500 || $statusCode >= 500 && $statusCode < 600) {
} elseif ($statusCode >= 400 && $statusCode < 500) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} elseif ($statusCode >= 500 && $statusCode < 600) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} else {
throw new \Dub\Models\Errors\SDKException('Unknown status code received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
Expand Down Expand Up @@ -859,7 +867,9 @@ public function update(Operations\UpdateCustomerRequest $request, ?Options $opti
} else {
throw new \Dub\Models\Errors\SDKException('Unknown content type received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
}
} elseif ($statusCode >= 400 && $statusCode < 500 || $statusCode >= 500 && $statusCode < 600) {
} elseif ($statusCode >= 400 && $statusCode < 500) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} elseif ($statusCode >= 500 && $statusCode < 600) {
throw new \Dub\Models\Errors\SDKException('API error occurred', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
} else {
throw new \Dub\Models\Errors\SDKException('Unknown status code received', $statusCode, $httpResponse->getBody()->getContents(), $httpResponse);
Expand Down
Loading

0 comments on commit bdde09e

Please sign in to comment.