# Provider

> **Package : spaceone.api.identity.v1**

## Provider

{% hint style="info" %}
**Provider Methods:**
{% endhint %}

| NO | Method                | Request Type                                    | Response Type                                                                                                      | Description |
| -- | --------------------- | ----------------------------------------------- | ------------------------------------------------------------------------------------------------------------------ | ----------- |
| 1  | [**create**](#create) | [CreateProviderRequest](#createproviderrequest) | [ProviderInfo](#providerinfo)                                                                                      |             |
| 2  | [**update**](#update) | [UpdateProviderRequest](#updateproviderrequest) | [ProviderInfo](#providerinfo)                                                                                      |             |
| 3  | [**delete**](#delete) | [ProviderRequest](#providerrequest)             | [google.protobuf.Empty](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/empty.proto)   |             |
| 4  | [**get**](#get)       | [GetProviderRequest](#getproviderrequest)       | [ProviderInfo](#providerinfo)                                                                                      |             |
| 5  | [**list**](#list)     | [ProviderQuery](#providerquery)                 | [ProvidersInfo](#providersinfo)                                                                                    |             |
| 6  | [**stat**](#stat)     | [ProviderStatQuery](#providerstatquery)         | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) |             |

### create

> **POST** /identity/v1/providers

| Type     | Message                                         |
| -------- | ----------------------------------------------- |
| Request  | [CreateProviderRequest](#createproviderrequest) |
| Response | [ProviderInfo](#providerinfo)                   |

### update

> **PUT** /identity/v1/provider/{provider\_id}

| Type     | Message                                         |
| -------- | ----------------------------------------------- |
| Request  | [UpdateProviderRequest](#updateproviderrequest) |
| Response | [ProviderInfo](#providerinfo)                   |

### delete

> **DELETE** /identity/v1/provider/{provider\_id}

| Type     | Message                                                                                                          |
| -------- | ---------------------------------------------------------------------------------------------------------------- |
| Request  | [ProviderRequest](#providerrequest)                                                                              |
| Response | [google.protobuf.Empty](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/empty.proto) |

### get

> **GET** /identity/v1/provider/{provider\_id}

| Type     | Message                                   |
| -------- | ----------------------------------------- |
| Request  | [GetProviderRequest](#getproviderrequest) |
| Response | [ProviderInfo](#providerinfo)             |

### list

> **GET** /identity/v1/providers
>
> **POST** /identity/v1/providers/search

| Type     | Message                         |
| -------- | ------------------------------- |
| Request  | [ProviderQuery](#providerquery) |
| Response | [ProvidersInfo](#providersinfo) |

### stat

> **POST** /identity/v1/providers/stat

| Type     | Message                                                                                                            |
| -------- | ------------------------------------------------------------------------------------------------------------------ |
| Request  | [ProviderStatQuery](#providerstatquery)                                                                            |
| Response | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) |

## Message

### CreateProviderRequest

| No | Field      | Type                                                                                                               | Required | Description |
| -- | ---------- | ------------------------------------------------------------------------------------------------------------------ | -------- | ----------- |
| 1  | provider   | string                                                                                                             | ✅        |             |
| 2  | name       | string                                                                                                             | ✅        |             |
| 3  | template   | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) | ❌        |             |
| 4  | metadata   | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) | ❌        |             |
| 5  | capability | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) | ❌        |             |
| 6  | tags       | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) | ❌        |             |
| 7  | domain\_id | string                                                                                                             | ✅        |             |

### GetProviderRequest

| No | Field      | Type           | Required | Description |
| -- | ---------- | -------------- | -------- | ----------- |
| 1  | provider   | string         | ✅        |             |
| 2  | only       | list of string | ❌        |             |
| 3  | domain\_id | string         | ✅        |             |

### ProviderInfo

| No | Field       | Type                                                                                                                     | Description |
| -- | ----------- | ------------------------------------------------------------------------------------------------------------------------ | ----------- |
| 1  | provider    | string                                                                                                                   |             |
| 2  | name        | string                                                                                                                   |             |
| 3  | template    | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto)       |             |
| 4  | metadata    | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto)       |             |
| 5  | capability  | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto)       |             |
| 6  | tags        | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto)       |             |
| 7  | created\_at | [google.protobuf.Timestamp](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/timestamp.proto) |             |

### ProviderQuery

| No | Field      | Type                                                                                               | Required | Description |
| -- | ---------- | -------------------------------------------------------------------------------------------------- | -------- | ----------- |
| 1  | query      | [spaceone.api.core.v1.Query](https://spaceone-dev.gitbook.io/api-reference/common-v1/search-query) | ❌        |             |
| 2  | provider   | string                                                                                             | ❌        |             |
| 3  | name       | string                                                                                             | ❌        |             |
| 4  | domain\_id | string                                                                                             | ✅        |             |

### ProviderRequest

| No | Field      | Type   | Required | Description |
| -- | ---------- | ------ | -------- | ----------- |
| 1  | provider   | string | ✅        |             |
| 2  | domain\_id | string | ✅        |             |

### ProviderStatQuery

| No | Field      | Type                                                                                                             | Required | Description |
| -- | ---------- | ---------------------------------------------------------------------------------------------------------------- | -------- | ----------- |
| 1  | query      | [spaceone.api.core.v1.StatisticsQuery](https://spaceone-dev.gitbook.io/api-reference/common-v1/statistics-query) | ✅        |             |
| 2  | domain\_id | string                                                                                                           | ✅        |             |

### ProvidersInfo

| No | Field        | Type                                                                                            | Description |
| -- | ------------ | ----------------------------------------------------------------------------------------------- | ----------- |
| 1  | results      | [list of ProviderInfo](#providerinfo)                                                           |             |
| 2  | total\_count | [int32](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/type.proto) |             |

### UpdateProviderRequest

| No | Field      | Type                                                                                                               | Required | Description |
| -- | ---------- | ------------------------------------------------------------------------------------------------------------------ | -------- | ----------- |
| 1  | provider   | string                                                                                                             | ✅        |             |
| 2  | name       | string                                                                                                             | ❌        |             |
| 3  | template   | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) | ❌        |             |
| 4  | metadata   | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) | ❌        |             |
| 5  | capability | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) | ❌        |             |
| 6  | tags       | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) | ❌        |             |
| 7  | domain\_id | string                                                                                                             | ✅        |             |
