Skip to content

Commit

Permalink
Merge pull request #63 from apideck-libraries/generator-update
Browse files Browse the repository at this point in the history
Automated update by SDK Generator
  • Loading branch information
ritik-singh07 authored Aug 28, 2024
2 parents b119bb1 + 740fe85 commit 4418baf
Show file tree
Hide file tree
Showing 30 changed files with 369 additions and 37 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ api_new.yml
vendor/
.env
/out
.idea
1 change: 1 addition & 0 deletions src/gen/docs/apis/HrisApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -1129,6 +1129,7 @@ Name | Type | Description | Notes
**x_apideck_service_id** | **string**| Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. |
**fields** | **string**| The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. <br /><br />Example: &#x60;fields=name,email,addresses.city&#x60;<br /><br />In the example above, the response will only include the fields \&quot;name\&quot;, \&quot;email\&quot; and \&quot;addresses.city\&quot;. If any other fields are available, they will be excluded. |
**filter** | [\Apideck\Client\Model\EmployeesOneFilter](../models/\Apideck\Client\Model\EmployeesOneFilter.md)| Apply filters |
**pass_through** | [\Apideck\Client\Model\PassThroughQuery](../models/\Apideck\Client\Model\PassThroughQuery.md)| Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads |
**raw** | [**bool**] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false


Expand Down
1 change: 1 addition & 0 deletions src/gen/docs/models/ActivitiesFilter.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Name | Type | Description | Notes
`owner_id` | **string** | Owner ID to filter on | [optional]
`contact_id` | **string** | Primary contact ID to filter on | [optional]
`updated_since` | **\DateTime** | | [optional]
`type` | **string** | Type to filter on | [optional]



Expand Down
2 changes: 2 additions & 0 deletions src/gen/docs/models/Bill.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ Name | Type | Description | Notes
`row_version` | **string** | A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. | [optional]
`custom_mappings` | **object** | When custom mappings are configured on the resource, the result is included here. | [optional]
`pass_through` | **object[]** | The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. | [optional]
`accounting_period` | **string** | Accounting period | [optional]



Expand Down Expand Up @@ -111,6 +112,7 @@ Name | Type | Description | Notes




---

[[Back to top]](#) [[Back to API list]](../../../../README.md#documentation-for-api-endpoints) [[Back to README]](../../../../README.md)
Expand Down
2 changes: 1 addition & 1 deletion src/gen/docs/models/Employee.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
`id` | **string** | A unique identifier for an object. |
`id` | **string** | A unique identifier for an object. | [optional]
`first_name` | **string** | The first name of the person. | [optional]
`last_name` | **string** | The last name of the person. | [optional]
`middle_name` | **string** | Middle name of the person. | [optional]
Expand Down
2 changes: 1 addition & 1 deletion src/gen/docs/models/InvoiceLineItem.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Name | Type | Description | Notes
`id` | **string** | A unique identifier for an object. | [optional]
`row_id` | **string** | Row ID | [optional]
`code` | **string** | User defined item code | [optional]
`line_number` | **int** | Line number in the invoice | [optional]
`line_number` | **int** | Line number of the resource | [optional]
`description` | **string** | User defined description | [optional]
`type` | **string** | Item type | [optional]
`tax_amount` | **float** | Tax amount | [optional]
Expand Down
2 changes: 2 additions & 0 deletions src/gen/docs/models/JournalEntry.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Name | Type | Description | Notes
`tax_code` | **string** | Applicable tax id/code override if tax is not supplied on a line item basis. | [optional]
`number` | **string** | Journal entry number. | [optional]
`tracking_categories` | [**\Apideck\Client\Model\LinkedTrackingCategory[]**](LinkedTrackingCategory.md) | A list of linked tracking categories. | [optional]
`accounting_period` | **string** | Accounting period | [optional]
`custom_mappings` | **object** | When custom mappings are configured on the resource, the result is included here. | [optional]
`updated_by` | **string** | The user who last updated the object. | [optional]
`created_by` | **string** | The user who created the object. | [optional]
Expand Down Expand Up @@ -52,6 +53,7 @@ Name | Type | Description | Notes




---

[[Back to top]](#) [[Back to API list]](../../../../README.md#documentation-for-api-endpoints) [[Back to README]](../../../../README.md)
Expand Down
2 changes: 2 additions & 0 deletions src/gen/docs/models/JournalEntryLineItem.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Name | Type | Description | Notes
`supplier` | [**\Apideck\Client\Model\LinkedSupplier**](LinkedSupplier.md) | | [optional]
`department_id` | **string** | A unique identifier for an object. | [optional]
`location_id` | **string** | A unique identifier for an object. | [optional]
`line_number` | **int** | Line number of the resource | [optional]



Expand Down Expand Up @@ -51,6 +52,7 @@ Name | Type | Description | Notes




---

[[Back to top]](#) [[Back to API list]](../../../../README.md#documentation-for-api-endpoints) [[Back to README]](../../../../README.md)
Expand Down
2 changes: 2 additions & 0 deletions src/gen/docs/models/Lead.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Name | Type | Description | Notes
`company_name` | **string** | The name of the company the lead is associated with. |
`id` | **string** | Unique identifier for the contact. | [optional]
`owner_id` | **string** | The owner of the lead. | [optional]
`owner_name` | **string** | The name of the owner of the lead. | [optional]
`company_id` | **string** | The company the lead is associated with. | [optional]
`lead_id` | **string** | The identifier of the lead. | [optional]
`lead_source` | **string** | The source of the lead. | [optional]
Expand Down Expand Up @@ -54,6 +55,7 @@ Name | Type | Description | Notes




* [`Currency`](Currency.md)

* [`Website`](Website.md)
Expand Down
2 changes: 2 additions & 0 deletions src/gen/docs/models/LedgerAccount.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ Name | Type | Description | Notes

* `COSTS_OF_SALES` (value: `'costs_of_sales'`)

* `OTHER` (value: `'other'`)




Expand Down
1 change: 1 addition & 0 deletions src/gen/docs/models/PurchaseOrdersFilter.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
`updated_since` | **\DateTime** | | [optional]
`supplier_id` | **string** | | [optional]



Expand Down
1 change: 1 addition & 0 deletions src/gen/docs/models/TrackingCategory.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ Name | Type | Description | Notes
`id` | **string** | A unique identifier for an object. | [optional]
`parent_id` | **string** | A unique identifier for an object. | [optional]
`name` | **string** | The name of the tracking category. | [optional]
`code` | **string** | The code of the tracking category. | [optional]
`status` | **string** | Based on the status some functionality is enabled or disabled. | [optional]
`custom_mappings` | **object** | When custom mappings are configured on the resource, the result is included here. | [optional]
`row_version` | **string** | A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. | [optional]
Expand Down
63 changes: 54 additions & 9 deletions src/gen/lib/Api/HrisApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -8616,14 +8616,15 @@ public function employeesDeleteRequest($id, $x_apideck_consumer_id = null, $x_ap
* @param bool $raw Include raw response. Mostly used for debugging purposes (optional, default to false)
* @param string $fields The &#39;fields&#39; parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. &lt;br /&gt;&lt;br /&gt;Example: &#x60;fields&#x3D;name,email,addresses.city&#x60;&lt;br /&gt;&lt;br /&gt;In the example above, the response will only include the fields \&quot;name\&quot;, \&quot;email\&quot; and \&quot;addresses.city\&quot;. If any other fields are available, they will be excluded. (optional)
* @param \Apideck\Client\Model\EmployeesOneFilter $filter Apply filters (optional)
* @param \Apideck\Client\Model\PassThroughQuery $pass_through Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]&#x3D;leads becomes ?search&#x3D;leads (optional)
*
* @throws \Apideck\Client\ApiException on non-2xx response
* @throws \InvalidArgumentException
* @return \Apideck\Client\Model\GetEmployeeResponse|\Apideck\Client\Model\BadRequestResponse|\Apideck\Client\Model\UnauthorizedResponse|\Apideck\Client\Model\PaymentRequiredResponse|\Apideck\Client\Model\NotFoundResponse|\Apideck\Client\Model\UnprocessableResponse|\Apideck\Client\Model\UnexpectedErrorResponse
*/
public function employeesOne($id, $x_apideck_consumer_id = null, $x_apideck_app_id = null, $x_apideck_service_id = null, $raw = false, $fields = null, $filter = null)
public function employeesOne($id, $x_apideck_consumer_id = null, $x_apideck_app_id = null, $x_apideck_service_id = null, $raw = false, $fields = null, $filter = null, $pass_through = null)
{
list($response) = $this->employeesOneWithHttpInfo($id, $x_apideck_consumer_id, $x_apideck_app_id, $x_apideck_service_id, $raw, $fields, $filter);
list($response) = $this->employeesOneWithHttpInfo($id, $x_apideck_consumer_id, $x_apideck_app_id, $x_apideck_service_id, $raw, $fields, $filter, $pass_through);
return $response;
}

Expand All @@ -8639,14 +8640,15 @@ public function employeesOne($id, $x_apideck_consumer_id = null, $x_apideck_app_
* @param bool $raw Include raw response. Mostly used for debugging purposes (optional, default to false)
* @param string $fields The &#39;fields&#39; parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. &lt;br /&gt;&lt;br /&gt;Example: &#x60;fields&#x3D;name,email,addresses.city&#x60;&lt;br /&gt;&lt;br /&gt;In the example above, the response will only include the fields \&quot;name\&quot;, \&quot;email\&quot; and \&quot;addresses.city\&quot;. If any other fields are available, they will be excluded. (optional)
* @param \Apideck\Client\Model\EmployeesOneFilter $filter Apply filters (optional)
* @param \Apideck\Client\Model\PassThroughQuery $pass_through Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]&#x3D;leads becomes ?search&#x3D;leads (optional)
*
* @throws \Apideck\Client\ApiException on non-2xx response
* @throws \InvalidArgumentException
* @return array of \Apideck\Client\Model\GetEmployeeResponse|\Apideck\Client\Model\BadRequestResponse|\Apideck\Client\Model\UnauthorizedResponse|\Apideck\Client\Model\PaymentRequiredResponse|\Apideck\Client\Model\NotFoundResponse|\Apideck\Client\Model\UnprocessableResponse|\Apideck\Client\Model\UnexpectedErrorResponse, HTTP status code, HTTP response headers (array of strings)
*/
public function employeesOneWithHttpInfo($id, $x_apideck_consumer_id = null, $x_apideck_app_id = null, $x_apideck_service_id = null, $raw = false, $fields = null, $filter = null)
public function employeesOneWithHttpInfo($id, $x_apideck_consumer_id = null, $x_apideck_app_id = null, $x_apideck_service_id = null, $raw = false, $fields = null, $filter = null, $pass_through = null)
{
$request = $this->employeesOneRequest($id, $x_apideck_consumer_id, $x_apideck_app_id, $x_apideck_service_id, $raw, $fields, $filter);
$request = $this->employeesOneRequest($id, $x_apideck_consumer_id, $x_apideck_app_id, $x_apideck_service_id, $raw, $fields, $filter, $pass_through);

try {
$options = $this->createHttpClientOption();
Expand Down Expand Up @@ -8858,13 +8860,14 @@ public function employeesOneWithHttpInfo($id, $x_apideck_consumer_id = null, $x_
* @param bool $raw Include raw response. Mostly used for debugging purposes (optional, default to false)
* @param string $fields The &#39;fields&#39; parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. &lt;br /&gt;&lt;br /&gt;Example: &#x60;fields&#x3D;name,email,addresses.city&#x60;&lt;br /&gt;&lt;br /&gt;In the example above, the response will only include the fields \&quot;name\&quot;, \&quot;email\&quot; and \&quot;addresses.city\&quot;. If any other fields are available, they will be excluded. (optional)
* @param \Apideck\Client\Model\EmployeesOneFilter $filter Apply filters (optional)
* @param \Apideck\Client\Model\PassThroughQuery $pass_through Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]&#x3D;leads becomes ?search&#x3D;leads (optional)
*
* @throws \InvalidArgumentException
* @return \GuzzleHttp\Promise\PromiseInterface
*/
public function employeesOneAsync($id, $x_apideck_consumer_id = null, $x_apideck_app_id = null, $x_apideck_service_id = null, $raw = false, $fields = null, $filter = null)
public function employeesOneAsync($id, $x_apideck_consumer_id = null, $x_apideck_app_id = null, $x_apideck_service_id = null, $raw = false, $fields = null, $filter = null, $pass_through = null)
{
return $this->employeesOneAsyncWithHttpInfo($id, $x_apideck_consumer_id, $x_apideck_app_id, $x_apideck_service_id, $raw, $fields, $filter)
return $this->employeesOneAsyncWithHttpInfo($id, $x_apideck_consumer_id, $x_apideck_app_id, $x_apideck_service_id, $raw, $fields, $filter, $pass_through)
->then(
function ($response) {
return $response[0];
Expand All @@ -8884,14 +8887,15 @@ function ($response) {
* @param bool $raw Include raw response. Mostly used for debugging purposes (optional, default to false)
* @param string $fields The &#39;fields&#39; parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. &lt;br /&gt;&lt;br /&gt;Example: &#x60;fields&#x3D;name,email,addresses.city&#x60;&lt;br /&gt;&lt;br /&gt;In the example above, the response will only include the fields \&quot;name\&quot;, \&quot;email\&quot; and \&quot;addresses.city\&quot;. If any other fields are available, they will be excluded. (optional)
* @param \Apideck\Client\Model\EmployeesOneFilter $filter Apply filters (optional)
* @param \Apideck\Client\Model\PassThroughQuery $pass_through Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]&#x3D;leads becomes ?search&#x3D;leads (optional)
*
* @throws \InvalidArgumentException
* @return \GuzzleHttp\Promise\PromiseInterface
*/
public function employeesOneAsyncWithHttpInfo($id, $x_apideck_consumer_id = null, $x_apideck_app_id = null, $x_apideck_service_id = null, $raw = false, $fields = null, $filter = null)
public function employeesOneAsyncWithHttpInfo($id, $x_apideck_consumer_id = null, $x_apideck_app_id = null, $x_apideck_service_id = null, $raw = false, $fields = null, $filter = null, $pass_through = null)
{
$returnType = '\Apideck\Client\Model\GetEmployeeResponse';
$request = $this->employeesOneRequest($id, $x_apideck_consumer_id, $x_apideck_app_id, $x_apideck_service_id, $raw, $fields, $filter);
$request = $this->employeesOneRequest($id, $x_apideck_consumer_id, $x_apideck_app_id, $x_apideck_service_id, $raw, $fields, $filter, $pass_through);

return $this->client
->sendAsync($request, $this->createHttpClientOption())
Expand Down Expand Up @@ -8936,11 +8940,12 @@ function ($exception) {
* @param bool $raw Include raw response. Mostly used for debugging purposes (optional, default to false)
* @param string $fields The &#39;fields&#39; parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. &lt;br /&gt;&lt;br /&gt;Example: &#x60;fields&#x3D;name,email,addresses.city&#x60;&lt;br /&gt;&lt;br /&gt;In the example above, the response will only include the fields \&quot;name\&quot;, \&quot;email\&quot; and \&quot;addresses.city\&quot;. If any other fields are available, they will be excluded. (optional)
* @param \Apideck\Client\Model\EmployeesOneFilter $filter Apply filters (optional)
* @param \Apideck\Client\Model\PassThroughQuery $pass_through Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]&#x3D;leads becomes ?search&#x3D;leads (optional)
*
* @throws \InvalidArgumentException
* @return \GuzzleHttp\Psr7\Request
*/
public function employeesOneRequest($id, $x_apideck_consumer_id = null, $x_apideck_app_id = null, $x_apideck_service_id = null, $raw = false, $fields = null, $filter = null)
public function employeesOneRequest($id, $x_apideck_consumer_id = null, $x_apideck_app_id = null, $x_apideck_service_id = null, $raw = false, $fields = null, $filter = null, $pass_through = null)
{
// verify the required parameter 'id' is set
if ($id === null || (is_array($id) && count($id) === 0)) {
Expand Down Expand Up @@ -9076,6 +9081,46 @@ public function employeesOneRequest($id, $x_apideck_consumer_id = null, $x_apide
$queryParams['filter'] = $filter;
}
}
// query params

if ('raw' === 'pass_through') {
// Support for raw as true/false parameter
if('form' === 'deepObject' && is_array($pass_through)) {
foreach($pass_through as $key => $value) {
$queryParams[$key] = $value;
}
}
else {
$queryParams['pass_through'] = $pass_through ? 'true' : 'false';
}
}


if ($pass_through !== null && 'sort' === 'pass_through') {
// Support for sort options
$sort_data = $sort->jsonSerialize();
foreach($sort_data as $key => $value) {
$queryParams['sort['.$key.']'] = $value;
}
}

if ($pass_through !== null && 'filter' === 'pass_through') {
// Support for filter options
$filter_data = $filter->jsonSerialize();
foreach($filter_data as $key => $value) {
$queryParams['filter['.$key.']'] = $value;
}
}
if ($pass_through !== null && !('pass_through' === 'raw' || 'pass_through' === 'sort' || 'pass_through' === 'filter')) {
if('form' === 'deepObject' && is_array($pass_through)) {
foreach($pass_through as $key => $value) {
$queryParams[$key] = $value;
}
}
else {
$queryParams['pass_through'] = $pass_through;
}
}

// header params
if ($x_apideck_consumer_id !== null) {
Expand Down
Loading

0 comments on commit 4418baf

Please sign in to comment.