Skip to content

Commit

Permalink
Merge pull request #66 from ggtakec/update_ghp
Browse files Browse the repository at this point in the history
[gh-pages] Updated TENANT API documents
  • Loading branch information
ggtakec committed Jul 25, 2023
2 parents 6c136ad + 35080d1 commit 924ce2b
Show file tree
Hide file tree
Showing 4 changed files with 75 additions and 5 deletions.
38 changes: 35 additions & 3 deletions api_tenant.md
Original file line number Diff line number Diff line change
Expand Up @@ -393,10 +393,42 @@ x-auth-token: U=<Scoped User Token>
### Response Body(JSON)
Empty

## DELETE
## DELETE (Tenant)
Specify Unscoped User Token or Scoped User Token and completely delete the Local Tenant(TENANT).
If the User(USER) specifies a Local Tenant(TENANT) that is not permitted to use, it will fail.

#### Note
All TENANT APIs require an Unscoped User Token or a Scoped User Token.
If a Scoped User Token is specified, the tenant indicated by that token will be ignored and only the USER information will be used as with the Unscoped User Token.

### Endpoint(URL)
http(s)://_API SERVER:PORT_/v1/tenant?tenant=_tenant name_?id=_tenant id_

### Header
```
Content-Type: application/json
x-auth-token: U=<Scoped User Token>
```

### URL argument
- tenant name
Specify the K2HR3 cluster Local Tenant(TENANT) name.
It is an error if this value is not prefixed with the `local@` prefix.
If the specified the K2HR3 cluster Local Tenant(TENANT) does not exist, it is failure.
- id
Specify the _ID_ of the K2HR3 cluster Local Tenant(TENANT).
If the K2HR3 Cluster Local Tenant(TENANT) name and this _ID_ value do not match, it will be failure.

### Response status
204, 40x

### Response Body(JSON)
Empty

## DELETE (User)
Specify Unscoped User Token or Scoped User Token and make the USER unavailable to the K2HR3 cluster Local Tenant(TENANT).
As a result of this process, if there are no more USER that can use the K2HR3 cluster Local Tenant(TENANT), the TENANT will be deleted.
The list of TENANTs that can be obtained is limited to the TENANT that the USER is permitted to use.
If the User(USER) specifies a Local Tenant(TENANT) that is not permitted to use, it will fail.

#### Note
All TENANT APIs require an Unscoped User Token or a Scoped User Token.
Expand All @@ -407,7 +439,7 @@ http(s)://_API SERVER:PORT_/v1/tenant/_tenant name_?id=_tenant id_

- tenant name
Specify the K2HR3 cluster Local Tenant(TENANT) name.
If this value does not have the `local@` prefix, it will automatically be changed to the TENANT name with the `local@` prefix.
It is an error if this value is not prefixed with the `local@` prefix.
If the specified the K2HR3 cluster Local Tenant(TENANT) does not exist, it is failure.

### Header
Expand Down
36 changes: 34 additions & 2 deletions api_tenantja.md
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,39 @@ x-auth-token: U=<Scoped User Token>
### Response Body(JSON)
なし

## DELETE
## DELETE(テナント)
Unscoped User Tokenもしくは、Scoped User Tokenを指定し、ローカルテナント(TENANT)を完全に削除します。
ユーザ(USER)が利用を許可されていないテナント(TENANT)を指定した場合、失敗します。

#### 注意
すべてのTENANT APIには、Unscoped User Tokenもしくは、Scoped User Tokenが必要です。
Scoped User Tokenが指定された場合、そのトークンが示すテナントは無視され、Unscoped User Tokenと同様にユーザ情報のみを使用します。

### Endpoint(URL)
http(s)://_API SERVER:PORT_/v1/tenant?tenant=_tenant name_?id=_tenant id_

### Header
```
Content-Type: application/json
x-auth-token: U=<Scoped User Token>
```

### URL argument
- tenant name
K2HR3クラスターローカルテナント(TENANT)名を指定します。
この値に `local@` プレフィックスが付与されていない場合、エラーになります。
指定したK2HR3クラスターローカルテナント(TENANT)が存在しない場合は失敗します。
- id
K2HR3クラスターローカルテナント(TENANT)の_ID_を指定します。
K2HR3クラスターローカルテナント(TENANT)名とこの_ID_が一致しない場合、失敗します。

### Response status
204、40x

### Response Body(JSON)
なし

## DELETE(ユーザ)
Unscoped User Tokenもしくは、Scoped User Tokenを指定し、ユーザ(USER)を K2HR3クラスターローカルテナント(TENANT)の利用不可にします。
この処理を行った結果、K2HR3クラスターローカルテナント(TENANT)の利用できるユーザ(USER)がいなくなった場合、K2HR3クラスターローカルテナント(TENANT)は削除されます。
ユーザ(USER)が利用を許可されていないテナント(TENANT)を指定した場合、失敗します。
Expand All @@ -409,7 +441,7 @@ http(s)://_API SERVER:PORT_/v1/tenant/_tenant name_?id=_tenant id_

- tenant name
K2HR3クラスターローカルテナント(TENANT)名を指定します。
この値に `local@` プレフィックスが付与されていない場合、自動的に `local@` プレフィックスが付与されたテナント(TENANT)名に変更されます
この値に `local@` プレフィックスが付与されていない場合、エラーになります
指定したK2HR3クラスターローカルテナント(TENANT)が存在しない場合は失敗します。

### Header
Expand Down
3 changes: 3 additions & 0 deletions whatnew.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ next_string: Detail
---

# What's new
## [25 Jul 2023] K2HR3 API updated
The source code of K2HR3 API (Version 1.0.27) has been released on Github.com.

## [13 Jul 2023] K2HR3 API updated
The source code of K2HR3 API (Version 1.0.26) has been released on Github.com.

Expand Down
3 changes: 3 additions & 0 deletions whatnewja.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ next_string: Detail
---

# What's new
## 2023年7月25日
K2HR3 API (Version 1.0.27) をリリースし、Github.comで公開しました。

## 2023年7月13日
K2HR3 API (Version 1.0.26) をリリースし、Github.comで公開しました。

Expand Down

0 comments on commit 924ce2b

Please sign in to comment.