# OrganizationIntegrationsApi

All URIs are relative to *https://admin-api.connected.dev*

|Method | HTTP request | Description|
|------------- | ------------- | -------------|
|[**createIntegration**](#createintegration) | **POST** /organization/integrations | Create an organization integration|
|[**deleteIntegration**](#deleteintegration) | **DELETE** /organization/integrations/{integrationId} | Delete an organization integration|
|[**getIntegration**](#getintegration) | **GET** /organization/integrations/{integrationId} | Get an organization integration|
|[**getIntegrations**](#getintegrations) | **GET** /organization/integrations | List an organization\&#39;s integrations|
|[**updateIntegration**](#updateintegration) | **PUT** /organization/integrations/{integrationId} | Update an organization integration|

# **createIntegration**
> CreateIntegration200Response createIntegration(integrationCreateInputs)

Creates a new third-party integration (e.g. Snagtag) for the organization, storing any provided secret key securely in AWS Secrets Manager; fails if an integration of that type already exists, and requires the \"update\" permission on \"org\".

### Example

```typescript
import {
    OrganizationIntegrationsApi,
    Configuration,
    IntegrationCreateInputs
} from '@connectedxm/admin-sdk';

const configuration = new Configuration();
const apiInstance = new OrganizationIntegrationsApi(configuration);

let integrationCreateInputs: IntegrationCreateInputs; //

const { status, data } = await apiInstance.createIntegration(
    integrationCreateInputs
);
```

### Parameters

|Name | Type | Description  | Notes|
|------------- | ------------- | ------------- | -------------|
| **integrationCreateInputs** | **IntegrationCreateInputs**|  | |


### Return type

**CreateIntegration200Response**

### Authorization

[ApiKeyAuth](../README.md#ApiKeyAuth), [OrganizationId](../README.md#OrganizationId)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json


### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
|**200** | Successful response |  -  |

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

# **deleteIntegration**
> CreateAccountInvitations200Response deleteIntegration()

Deletes the specified integration configured for the organization, also removing its stored secret from AWS Secrets Manager if one exists, and requires the \"update\" permission on \"org\".

### Example

```typescript
import {
    OrganizationIntegrationsApi,
    Configuration
} from '@connectedxm/admin-sdk';

const configuration = new Configuration();
const apiInstance = new OrganizationIntegrationsApi(configuration);

let integrationId: string; //The integration identifier (default to undefined)

const { status, data } = await apiInstance.deleteIntegration(
    integrationId
);
```

### Parameters

|Name | Type | Description  | Notes|
|------------- | ------------- | ------------- | -------------|
| **integrationId** | [**string**] | The integration identifier | defaults to undefined|


### Return type

**CreateAccountInvitations200Response**

### Authorization

[ApiKeyAuth](../README.md#ApiKeyAuth), [OrganizationId](../README.md#OrganizationId)

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json


### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
|**200** | Successful response |  -  |

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

# **getIntegration**
> CreateIntegration200Response getIntegration()

Returns the details of a single third-party integration configured for the organization, identified by integration ID, with any stored secret masked; requires read access to the organization.

### Example

```typescript
import {
    OrganizationIntegrationsApi,
    Configuration
} from '@connectedxm/admin-sdk';

const configuration = new Configuration();
const apiInstance = new OrganizationIntegrationsApi(configuration);

let integrationId: string; //The integration identifier (default to undefined)

const { status, data } = await apiInstance.getIntegration(
    integrationId
);
```

### Parameters

|Name | Type | Description  | Notes|
|------------- | ------------- | ------------- | -------------|
| **integrationId** | [**string**] | The integration identifier | defaults to undefined|


### Return type

**CreateIntegration200Response**

### Authorization

[ApiKeyAuth](../README.md#ApiKeyAuth), [OrganizationId](../README.md#OrganizationId)

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json


### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
|**200** | Successful response |  -  |

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

# **getIntegrations**
> GetIntegrations200Response getIntegrations()

Returns a paginated list of third-party integrations configured for the organization, with any stored secrets masked, sortable via orderBy; requires read access to the organization.

### Example

```typescript
import {
    OrganizationIntegrationsApi,
    Configuration
} from '@connectedxm/admin-sdk';

const configuration = new Configuration();
const apiInstance = new OrganizationIntegrationsApi(configuration);

let page: number; //Page number (optional) (default to 1)
let pageSize: number; //Number of items per page (optional) (default to 25)
let orderBy: string; //Field to order by (optional) (default to undefined)
let search: string; //Search query (optional) (default to undefined)

const { status, data } = await apiInstance.getIntegrations(
    page,
    pageSize,
    orderBy,
    search
);
```

### Parameters

|Name | Type | Description  | Notes|
|------------- | ------------- | ------------- | -------------|
| **page** | [**number**] | Page number | (optional) defaults to 1|
| **pageSize** | [**number**] | Number of items per page | (optional) defaults to 25|
| **orderBy** | [**string**] | Field to order by | (optional) defaults to undefined|
| **search** | [**string**] | Search query | (optional) defaults to undefined|


### Return type

**GetIntegrations200Response**

### Authorization

[ApiKeyAuth](../README.md#ApiKeyAuth), [OrganizationId](../README.md#OrganizationId)

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json


### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
|**200** | Successful response |  -  |

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

# **updateIntegration**
> CreateIntegration200Response updateIntegration(integrationUpdateInputs)

Updates an existing integration\'s settings, such as enabled state, public URL, public key, or secret key (re-stored in AWS Secrets Manager), and requires the \"update\" permission on \"org\".

### Example

```typescript
import {
    OrganizationIntegrationsApi,
    Configuration,
    IntegrationUpdateInputs
} from '@connectedxm/admin-sdk';

const configuration = new Configuration();
const apiInstance = new OrganizationIntegrationsApi(configuration);

let integrationId: string; //The integration identifier (default to undefined)
let integrationUpdateInputs: IntegrationUpdateInputs; //

const { status, data } = await apiInstance.updateIntegration(
    integrationId,
    integrationUpdateInputs
);
```

### Parameters

|Name | Type | Description  | Notes|
|------------- | ------------- | ------------- | -------------|
| **integrationUpdateInputs** | **IntegrationUpdateInputs**|  | |
| **integrationId** | [**string**] | The integration identifier | defaults to undefined|


### Return type

**CreateIntegration200Response**

### Authorization

[ApiKeyAuth](../README.md#ApiKeyAuth), [OrganizationId](../README.md#OrganizationId)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json


### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
|**200** | Successful response |  -  |

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

