Skip to content

Commit

Permalink
Automated update by SDK Generator (#175)
Browse files Browse the repository at this point in the history
  • Loading branch information
nicklloyd authored Nov 20, 2024
1 parent 2d3c66e commit 83f1b3d
Show file tree
Hide file tree
Showing 692 changed files with 1,858 additions and 1,354 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@apideck/node",
"version": "3.4.3",
"version": "3.4.4",
"description": "Apideck Node.js SDK",
"keywords": [
"apideck",
Expand Down
2 changes: 1 addition & 1 deletion src/Apideck.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export class Apideck {
'x-apideck-app-id': config.appId,
'x-apideck-consumer-id': config.consumerId || '',
'x-apideck-service-id': config?.serviceId || '',
'user-agent': 'Apideck-node-sdk/3.4.3 Unify-spec/10.7.7'
'user-agent': 'Apideck-node-sdk/3.4.4 Unify-spec/10.8.1'
}
})

Expand Down
6 changes: 6 additions & 0 deletions src/gen/.openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,9 @@ CreateAttachmentRequest.md
CreateAttachmentResponse.md
CreateBillPaymentResponse.md
CreateBillResponse.md
CreateCallbackState.md
CreateCallbackStateResponse.md
CreateCallbackStateResponseData.md
CreateCommentResponse.md
CreateCompanyResponse.md
CreateConnectionResponse.md
Expand Down Expand Up @@ -834,6 +837,9 @@ models/CreateAttachmentRequest.ts
models/CreateAttachmentResponse.ts
models/CreateBillPaymentResponse.ts
models/CreateBillResponse.ts
models/CreateCallbackState.ts
models/CreateCallbackStateResponse.ts
models/CreateCallbackStateResponseData.ts
models/CreateCommentResponse.ts
models/CreateCompanyResponse.ts
models/CreateConnectionResponse.ts
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/AccountingApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/AtsApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/ConnectorApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/CrmApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/EcommerceApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/FileStorageApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/HrisApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/IssueTrackingApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/LeadApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/PosApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/SmsApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
94 changes: 93 additions & 1 deletion src/gen/apis/VaultApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand All @@ -21,6 +21,10 @@ import {
ConsumerRequestCountsInDateRangeResponse,
ConsumerRequestCountsInDateRangeResponseFromJSON,
ConsumerToJSON,
CreateCallbackState,
CreateCallbackStateResponse,
CreateCallbackStateResponseFromJSON,
CreateCallbackStateToJSON,
CreateConnectionResponse,
CreateConnectionResponseFromJSON,
CreateConsumerResponse,
Expand Down Expand Up @@ -162,6 +166,14 @@ export interface VaultApiConsumersUpdateRequest {
appId?: string
}

export interface VaultApiCreateCallbackStateRequest {
serviceId: string
unifiedApi: string
createCallbackState: CreateCallbackState
consumerId?: string
appId?: string
}

export interface VaultApiCustomFieldsAllRequest {
unifiedApi: string
serviceId: string
Expand Down Expand Up @@ -1229,6 +1241,86 @@ export class VaultApi extends runtime.BaseAPI {
return await response.value()
}

/**
* This endpoint creates a callback state that can be used to issue requests to the callback endpoint.
* Create Callback State
*/
async createCallbackStateRaw(
requestParameters: VaultApiCreateCallbackStateRequest,
initOverrides?: RequestInit
): Promise<runtime.ApiResponse<CreateCallbackStateResponse>> {
if (requestParameters.serviceId === null || requestParameters.serviceId === undefined) {
throw new runtime.RequiredError(
'serviceId',
'Required parameter requestParameters.serviceId was null or undefined when calling createCallbackState.'
)
}

if (requestParameters.unifiedApi === null || requestParameters.unifiedApi === undefined) {
throw new runtime.RequiredError(
'unifiedApi',
'Required parameter requestParameters.unifiedApi was null or undefined when calling createCallbackState.'
)
}

if (
requestParameters.createCallbackState === null ||
requestParameters.createCallbackState === undefined
) {
throw new runtime.RequiredError(
'createCallbackState',
'Required parameter requestParameters.createCallbackState was null or undefined when calling createCallbackState.'
)
}

const queryParameters: any = {}

const headerParameters: runtime.HTTPHeaders = {}

headerParameters['Content-Type'] = 'application/json'

if (requestParameters.consumerId !== undefined && requestParameters.consumerId !== null) {
headerParameters['x-apideck-consumer-id'] = String(requestParameters.consumerId)
}

if (requestParameters.appId !== undefined && requestParameters.appId !== null) {
headerParameters['x-apideck-app-id'] = String(requestParameters.appId)
}

if (this.configuration && this.configuration.apiKey) {
headerParameters['Authorization'] = this.configuration.apiKey('Authorization') // apiKey authentication
}

const response = await this.request(
{
path: `/vault/connections/{unified_api}/{service_id}/callback-state`
.replace(`{${'service_id'}}`, encodeURIComponent(String(requestParameters.serviceId)))
.replace(`{${'unified_api'}}`, encodeURIComponent(String(requestParameters.unifiedApi))),
method: 'POST',
headers: headerParameters,
query: queryParameters,
body: CreateCallbackStateToJSON(requestParameters.createCallbackState)
},
initOverrides
)

return new runtime.JSONApiResponse(response, jsonValue =>
CreateCallbackStateResponseFromJSON(jsonValue)
)
}

/**
* This endpoint creates a callback state that can be used to issue requests to the callback endpoint.
* Create Callback State
*/
async createCallbackState(
requestParameters: VaultApiCreateCallbackStateRequest,
initOverrides?: RequestInit
): Promise<CreateCallbackStateResponse> {
const response = await this.createCallbackStateRaw(requestParameters, initOverrides)
return await response.value()
}

/**
* This endpoint returns an custom fields on a connection resource.
* Get resource custom fields
Expand Down
2 changes: 1 addition & 1 deletion src/gen/apis/WebhookApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Apideck
* The Apideck OpenAPI Spec: SDK Optimized
*
* The version of the OpenAPI document: 10.7.7
* The version of the OpenAPI document: 10.8.1
* Contact: support@apideck.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 2 additions & 0 deletions src/gen/docs/apis/HrisApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -1260,6 +1260,7 @@ const params = {
hired_at: '2020-08-12',
is_primary: true,
is_manager: true,
status: 'active',
location: {
id: '123',
type: 'primary',
Expand Down Expand Up @@ -1770,6 +1771,7 @@ const params = {
hired_at: '2020-08-12',
is_primary: true,
is_manager: true,
status: 'active',
location: {
id: '123',
type: 'primary',
Expand Down
74 changes: 74 additions & 0 deletions src/gen/docs/apis/VaultApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
* [Delete Consumer](#consumersDelete)
* [Get Consumer](#consumersOne)
* [Update Consumer](#consumersUpdate)
* [Create Callback State](#createCallbackState)
* [Get Resource Custom Fields](#customFieldsAll)
* [List Custom Mappings](#customMappingsAll)
* [Get All Consumer Request Logs](#logsAll)
Expand Down Expand Up @@ -1142,6 +1143,79 @@ try {
```


[[Back to top]](#) [[Back to API list]](../../../../README.md#documentation-for-api-endpoints) [[Back to README]](../../../../README.md)

<a name="createCallbackState"></a>
# Create Callback State


Method: **createCallbackState**

```typescript
vaultApi.createCallbackState(body)
```

### Parameters

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**createCallbackState** | [CreateCallbackState](../models/CreateCallbackState.md)| Callback state data |
**serviceId** | [**string**] | Service ID of the resource to return |
**unifiedApi** | [**string**] | Unified API |
**consumerId** | [**string**] | ID of the consumer which you want to get or push data from | (optional)
**appId** | [**string**] | The ID of your Unify application | (optional)



### Response Type

[`CreateCallbackStateResponse`](../models/CreateCallbackStateResponse.md)



### HTTP response details
| Status code | Description |
|-------------|-------------|
**200** | Callback state created |
**400** | Bad Request |
**401** | Unauthorized |
**402** | Payment Required |
**404** | The specified resource was not found |
**422** | Unprocessable |
4/5xx | Unexpected error |


## Example Usage

```typescript
import { Apideck } from '@apideck/node';

const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});

const params = {
serviceId: 'pipedrive',
unifiedApi: 'crm',
createCallbackState: {
redirect_uri: 'https://example.com/callback'
}
}

try {
const { data } = await apideck.vault.createCallbackState(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}


```


[[Back to top]](#) [[Back to API list]](../../../../README.md#documentation-for-api-endpoints) [[Back to README]](../../../../README.md)

<a name="customFieldsAll"></a>
Expand Down
18 changes: 18 additions & 0 deletions src/gen/docs/models/CreateCallbackState.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Apideck.CreateCallbackState

### Description

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
`redirect_uri` | **string** | The redirect URI to be used after the connection is created. | [optional]





---

[[Back to top]](#) [[Back to API list]](../../../../README.md#documentation-for-api-endpoints) [[Back to README]](../../../../README.md)


Loading

0 comments on commit 83f1b3d

Please sign in to comment.