# Token

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

## Token

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

| Method                  | Request                                                                                                          | Response                |
| ----------------------- | ---------------------------------------------------------------------------------------------------------------- | ----------------------- |
| [**issue**](#issue)     | [IssueTokenRequest](#issuetokenrequest)                                                                          | [TokenInfo](#tokeninfo) |
| [**refresh**](#refresh) | [google.protobuf.Empty](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/empty.proto) | [TokenInfo](#tokeninfo) |

### issue

> **POST** /identity/v1/token/issue

| Type     | Message                                 |
| -------- | --------------------------------------- |
| Request  | [IssueTokenRequest](#issuetokenrequest) |
| Response | [TokenInfo](#tokeninfo)                 |

### refresh

> **POST** /identity/v1/token/refresh

| Type     | Message                 |
| -------- | ----------------------- |
| Request  | \[Empty]                |
| Response | [TokenInfo](#tokeninfo) |

##

## Message

### IssueTokenRequest

| Field          | Type                                                                                                               | Required | Description |
| -------------- | ------------------------------------------------------------------------------------------------------------------ | :------: | ----------- |
| user\_id       | string                                                                                                             |     ✘    |             |
| credentials    | [google.protobuf.Struct](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/struct.proto) |     ✔    |             |
| user\_type     | string                                                                                                             |     ✘    |             |
| domain\_id     | string                                                                                                             |     ✔    |             |
| timeout        | [int32](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/type.proto)                    |     ✘    |             |
| refresh\_count | [int32](https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/type.proto)                    |     ✘    |             |

### TokenInfo

| Field          | Type   | Description |
| -------------- | ------ | ----------- |
| access\_token  | string |             |
| refresh\_token | string |             |
