役割一覧取得
GET /roles
GET
/roles
役割一覧を取得します。
対象
- プラン
- スタンダード
- プレミアム
- プレミアムプラス
- エンタープライズ
対象ユーザー権限
- 事業所管理閲覧
Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Query Parameters
Section titled “Query Parameters ” store_id
required
string
事業所ID(カンマ区切りで複数指定可)
指定した事業所IDに1件でも参照権限のないものが含まれる場合は 403 を返します。
Examples
単一指定
1複数指定
1,2 limit
integer
上限値
Example
50 page
integer
検索対象ページ番号
Example
2 sort
string
ソート順
パラメータ名で昇順、パラメータ名:descで降順指定可。カンマ区切りで複数項目指定可。
指定可能キー:
store_iddisplay_sequencerole_id
指定しない場合、store_id, display_sequence, role_id の昇順でソートされます。
Examples
単一指定
display_sequence複数指定
store_id,display_sequence,role_id:descResponses
Section titled “ Responses ”取得成功
object
count
件数
number
page
現在のページ番号
number
pageCount
総ページ数
number
roles
役割一覧
Array<object>
object
storeId
事業所ID
string
roleId
役割ID
string
roleName
役割名
string
description
説明
string
displaySequence
表示順
integer
Example
{ "count": 3, "page": 1, "pageCount": 1, "roles": [ { "storeId": "1", "roleId": "1", "roleName": "店長", "description": "店舗全体の運用責任者", "displaySequence": 1 }, { "storeId": "1", "roleId": "2", "roleName": "一般", "description": "", "displaySequence": null }, { "storeId": "2", "roleId": "5", "roleName": "責任者", "description": "シフト承認担当", "displaySequence": 1 } ]}Headers
Section titled “Headers ” Link
string
<前のURI>; rel="prev", <次のURI>; rel="next"
- パラメータに誤りがある場合
sortの指定形式が不正、または未許可キーが指定された場合
object
type
エラータイプを識別するURI、もしくはabout:blank
string
title
エラーの概要
string
detail
エラーの詳細
string
Example
{ "type": "about:blank", "title": "Bad Request", "detail": "sort には store_id, display_sequence, role_id のみ指定可能です。"}指定した store_id に参照権限のない事業所が含まれる場合
object
type
エラータイプを識別するURI、もしくはabout:blank
string
title
エラーの概要
string
detail
エラーの詳細
string
Example
{ "type": "about:blank", "title": "Forbidden", "detail": "ユーザーに権限のない事業所が指定されています: 2, 3"}