リポジトリ割当済タクソノミ・カテゴリのリスト
/content/management/api/v1.1/repositories/{id}/assignedTaxonomies/{taxonomyId}/categories
リクエスト
- id: string
リポジトリのId。
- taxonomyId: string
割当済タクソノミのID
- fields(optional): string
このパラメータは、リスト内の割り当てられた各カテゴリで返されるフィールドを制御するために使用されます。 このパラメータは、フィールド名のカンマ区切りリストを受け入れます。 これらのフィールドは、リストの割当済カテゴリに対して返されます。 すべてのフィールド名は大/小文字が区別され、ユーザーは問合せで正しいフィールド名を指定する必要があります。 各割当済カテゴリには、次のフィールドを設定できます: id, name, description, apiName, position, isSiteCategory, parent, 祖先, allowedActions, descendantsAllowedActions. このパラメータはオプションです。 存在しない場合、レスポンスにデフォルトのフィールドが返されます: id, name, description。 パラメータに正しくない、または無効なフィールド名を指定すると、エラーがスローされます。
例: ?fields=id,name,apiName,ancestors,allowedActions,descendantsAllowedActions
これにより、割り当てられた各カテゴリのid、name、apiName、祖先、allowedActionsおよびdescendantsAllowedActionsフィールドが戻されます。
- limit(optional): integer(int32)
このパラメータは、負でない整数を受け入れ、結果のサイズの制御に使用します。デフォルト値:
25 - links(optional): string
このパラメータは、リンク名のカンマ区切りのリストを受け入れます。 デフォルトでは、このパラメータによって、適用可能なすべてのリンクが指定されます。 可能な値は次のとおりです: self, canonical, describedby, first, 最後, prev, next
- offset(optional): integer(int32)
このパラメータは、負でない整数を受け入れ、結果の開始インデックスを制御するために使用します。デフォルト値:
0 - orderBy(optional): string
このパラメータは、結果の順序を制御するために使用します。 この問合せパラメータの値は、fieldName:[asc/desc]の書式に従います。「昇順」は昇順、「説明」は降順、デフォルトの順序は「昇順」です。フィールド名に使用できるフィールドは、nameおよびpositionのみです。 このパラメータのデフォルト値は「名前:asc」です。デフォルト値:
name:asc - q: string
このパラメータは、フィールド値に一致する問合せ式条件を受け入れます。 問合せ条件は、AND、ORおよびNOT論理演算子を使用して結合し、カッコでグループ化できます。 単項演算子を使用した問合せ条件は、{fieldName} {unary operator}の形式に従います。 バイナリ演算子を使用する問合せ条件は、{fieldName} {binary operator} "{fieldValue}"の形式に従います。 許可されるフィールド名は、parent、parent.id、name、allowedActionsおよびdescendantsAllowedActionsのみです。 問合せに同じ名前付きフィールドを持つ複数の条件を含めることはできません。 parentまたはparent.idフィールドを介して親カテゴリに関する条件を1つのみ指定するか、nameフィールドを介してカテゴリ名に条件を1つ指定する必要があります。
許可される演算子はparentのpr (現在)のみであり、論理演算子は親PR条件に適用できません。
許可される演算子は、parent.idのeq (等しい)のみです。
許可される演算子はnameのco (Contains)のみであり、その値では大/小文字が区別されません。
許可される演算子はallowedActionsのeq (等号)のみで、許可される値は"ASSET_CATEGORIZE"または"SITE_CREATE"です。
許可される演算子はdescendantsAllowedActionsのeq (等号)のみで、許可される値は"ASSET_CATEGORIZE"または"SITE_CREATE"です。
例:
?q=(NOT parent pr) AND (allowedActions eq "SITE_CREATE"またはdescendantsAllowedActions eq "SITE_CREATE")
この問合せは、割り当てられたタクソノミの最上位レベル・カテゴリをフィルタ処理して、カテゴリまたはカテゴリの子孫に対してユーザーがサイトの作成権限を持つカテゴリを返します。
例:
?q=(parent.id eq "2E0C45CF1C1147F590448FC355437149") AND (allowedActions eq "ASSET_CATEGORIZE"またはdescendantsAllowedActions eq "ASSET_CATEGORIZE")
この問合せでは、割り当てられたタクソノミのID "2E0C45CF1C1147F590448FC355437149"のカテゴリの下の子カテゴリをフィルタして、ユーザーがカテゴリまたはカテゴリの子孫に対してカテゴリ分類権限を持っているカテゴリを返します。
例:
?q=(name co "org") AND (allowedActions eq "ASSET_CATEGORIZE")
この問合せでは、割り当てられたタクソノミのカテゴリをフィルタ処理して、名前が"org"の大/小文字を含み、かつユーザーにカテゴリ化権限があるものを返します。 - totalResults(optional): boolean
このパラメータは、ブール・フラグを受け入れます。 trueとして指定した場合、返される結果には合計結果数が含まれる必要があります。デフォルト値:
false
レスポンス
- application/json
200レスポンス
object- aggregationResults(optional): array aggregationResults
集計結果。
- count(optional): integer(int32)
現在のレスポンス内のレコードの合計数
- hasMore(optional): boolean
フェッチするページがまだあるかどうかを確認します。
- items(optional): array items
コレクションに含まれる特異なリソース。
- limit(optional): integer(int32)
サーバーによって使用される実際のページ・サイズ。 これは、クライアントがリクエストするものと同じではない可能性があります。
- links(optional): array links
リソースのリンク。
- offset(optional): integer(int32)
特異リソースが返される実際のインデックス。
- pinned(optional): array pinned
固定品目。 検索リストの上部に固定されたアイテムを表示
- scrollId(optional): string
scrollId:検索がスクロール検索に解決された場合。
- totalResults(optional): integer(int32)
クライアント・リクエストを満たすローの総数(ページング・パラメータを除く)
array- Array of: object AssignedCategory
AssignedCategory
object- allowedActions(optional): array allowedActions
割当済カテゴリの許容処理。 アクションは、"ASSET_CATEGORIZE"および"SITE_CREATE"です。
- ancestors(optional): array ancestors
ルート・カテゴリから直近の親カテゴリまでのトップダウン順序でリストされる、割当済カテゴリの祖先。
- apiName(optional): string
割り当てられたカテゴリのAPI名。
- descendantsAllowedActions(optional): array descendantsAllowedActions
割当済カテゴリの子孫の集計可能な処理。 アクションは、"ASSET_CATEGORIZE"および"SITE_CREATE"です。 カテゴリに子がない場合、アクションは空の配列になります。
- description(optional): string
割当済カテゴリの摘要。
- id(optional): string
割当済カテゴリのID。
- isSiteCategory(optional): boolean
割当済カテゴリがサイト・カテゴリかどうか。
- links(optional): array links
割り当てられたタクソノミ・リソースのリンク。
- name(optional): string
割当済カテゴリの名前。
- parent(optional): object CategoryAncestorBean
- position(optional): integer(int32)
兄弟間での割当済カテゴリの位置。
arrayarrayobject- apiName(optional): string
カテゴリ祖先のapiName
- id(optional): string
カテゴリ祖先のid。
- name(optional): string
カテゴリ祖先の名前。
object- href(optional): string
ターゲット・リソースのURI それはテンプレートURIである可能性があります。 これはレスポンス取得の必須プロパティです。
- mediaType(optional): string
メディア・タイプ。
- method(optional): string
ターゲット・リソースへのアクセスに使用できるHTTPメソッド。
- profile(optional): string
ターゲット・リソースを記述するメタデータにリンクします。
- rel(optional): string
関連タイプ これはレスポンス取得の必須プロパティです。
- templated(optional): boolean
URIがテンプレートであるかどうか。
304 レスポンス
400レスポンス
403レスポンス
404レスポンス
500レスポンス
例
次の例は、cURLを使用してGETリクエストを発行することによって、リポジトリに割り当てられたタクソノミのカテゴリをリストする方法を示しています。
curl -X GET -H 'Accept: application/json' 'https://host:port/content/management/api/v1.1/repositories/{id}/assignedTaxonomies/{taxonomyId}/categories'
例1:
ここには、リポジトリ720E2B7391E64FB9A1EB5FA6DEA8F4C7に割り当てられているタクソノミFB8240D6DC70407F87ED111325D06F89のトップ・レベル・カテゴリがリストされます。この場合、ユーザーはカテゴリまたはその子孫に対するASSET_CATEGORIZE権限を持っており、カテゴリ位置の昇順でソートされます。
/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?offset=0&limit=10&orderBy=position:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions&totalResults=true&q=(NOT parent pr) AND (allowedActions eq \"ASSET_CATEGORIZE\" OR descendantsAllowedActions eq \"ASSET_CATEGORIZE\")
レスポンス本文
{
"hasMore": false,
"offset": 0,
"count": 2,
"limit": 2,
"totalResults": 2,
"items": [
{
"id": "03C2AB780DDD442CAC90328A0CA6687E",
"name": "Region East",
"apiName": "org-r",
"position": 0,
"isSiteCategory": false,
"ancestors": [],
"allowedActions": [],
"descendantsAllowedActions": [
"ASSET_CATEGORIZE",
"SITE_CREATE"
],
"links": [
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories/03C2AB780DDD442CAC90328A0CA6687E",
"rel": "self",
"method": "GET",
"mediaType": "application/json"
}
]
},
{
"id": "13C36CDABB764F1C866DF233F7F7DB4A",
"name": "Region West",
"apiName": "org-r1",
"position": 1,
"isSiteCategory": false,
"ancestors": [],
"allowedActions": [
"ASSET_CATEGORIZE"
],
"descendantsAllowedActions": [],
"links": [
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories/13C36CDABB764F1C866DF233F7F7DB4A",
"rel": "self",
"method": "GET",
"mediaType": "application/json"
}
]
}
],
"links": [
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(NOT parent pr) AND (allowedActions eq \"ASSET_CATEGORIZE\" OR descendantsAllowedActions eq \"ASSET_CATEGORIZE\")&totalResults=true&offset=0&limit=10&orderBy=position:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "self",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(NOT parent pr) AND (allowedActions eq \"ASSET_CATEGORIZE\" OR descendantsAllowedActions eq \"ASSET_CATEGORIZE\")&totalResults=true&offset=0&limit=10&orderBy=position:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "canonical",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/metadata-catalog/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories",
"rel": "describedby",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(NOT parent pr) AND (allowedActions eq \"ASSET_CATEGORIZE\" OR descendantsAllowedActions eq \"ASSET_CATEGORIZE\")&totalResults=true&offset=0&limit=10&orderBy=position:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "first",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(NOT parent pr) AND (allowedActions eq \"ASSET_CATEGORIZE\" OR descendantsAllowedActions eq \"ASSET_CATEGORIZE\")&totalResults=true&offset=0&limit=10&orderBy=position:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "last",
"method": "GET",
"mediaType": "application/json"
}
]
}
例2:
これによって、リポジトリ720E2B7391E64FB9A1EB5FA6DEA8F4C7に割り当てられたタクソノミFB8240D6DC70407F87ED111325D06F89の親カテゴリ03C2AB780DDD442CAC90328A0CA6687Eの下にカテゴリがリストされます。この場合、ユーザーはカテゴリまたはその子孫に対するASSET_CATEGORIZE権限を持ち、カテゴリ位置の昇順でソートされます。
/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?offset=0&limit=10&orderBy=position:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions&totalResults=true&q=(parent.id eq \"03C2AB780DDD442CAC90328A0CA6687E\") AND (allowedActions eq \"ASSET_CATEGORIZE\" OR descendantsAllowedActions eq \"ASSET_CATEGORIZE\")
レスポンス本文
{
"hasMore": false,
"offset": 0,
"count": 1,
"limit": 1,
"totalResults": 1,
"items": [
{
"id": "8A34CF67453E4BDE94505476C03B1066",
"name": "IT East",
"apiName": "org-r-i",
"position": 2,
"isSiteCategory": false,
"parent": {
"id": "03C2AB780DDD442CAC90328A0CA6687E",
"name": "Region East",
"apiName": "org-r"
},
"ancestors": [
{
"id": "03C2AB780DDD442CAC90328A0CA6687E",
"name": "Region East",
"apiName": "org-r"
}
],
"allowedActions": [
"ASSET_CATEGORIZE",
"SITE_CREATE"
],
"descendantsAllowedActions": [],
"links": [
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories/8A34CF67453E4BDE94505476C03B1066",
"rel": "self",
"method": "GET",
"mediaType": "application/json"
}
]
}
],
"links": [
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(parent.id eq \"03C2AB780DDD442CAC90328A0CA6687E\") AND (allowedActions eq \"ASSET_CATEGORIZE\" OR descendantsAllowedActions eq \"ASSET_CATEGORIZE\")&totalResults=true&offset=0&limit=10&orderBy=position:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "self",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(parent.id eq \"03C2AB780DDD442CAC90328A0CA6687E\") AND (allowedActions eq \"ASSET_CATEGORIZE\" OR descendantsAllowedActions eq \"ASSET_CATEGORIZE\")&totalResults=true&offset=0&limit=10&orderBy=position:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "canonical",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/metadata-catalog/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories",
"rel": "describedby",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(parent.id eq \"03C2AB780DDD442CAC90328A0CA6687E\") AND (allowedActions eq \"ASSET_CATEGORIZE\" OR descendantsAllowedActions eq \"ASSET_CATEGORIZE\")&totalResults=true&offset=0&limit=10&orderBy=position:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "first",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(parent.id eq \"03C2AB780DDD442CAC90328A0CA6687E\") AND (allowedActions eq \"ASSET_CATEGORIZE\" OR descendantsAllowedActions eq \"ASSET_CATEGORIZE\")&totalResults=true&offset=0&limit=10&orderBy=position:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "last",
"method": "GET",
"mediaType": "application/json"
}
]
}
例3 :
これによって、リポジトリ720E2B7391E64FB9A1EB5FA6DEA8F4C7に割り当てられるタクソノミFB8240D6DC70407F87ED111325D06F89のカテゴリがリストされます。その名前には大文字と小文字の"east"が含まれ、カテゴリに対するSITE_CREATE権限があり、カテゴリ名の昇順でソートされます。
/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?offset=0&limit=10&orderBy=name:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions&totalResults=true&q=name co \"east\" AND allowedActions eq \"SITE_CREATE\"
レスポンス本文
{
"hasMore": false,
"offset": 0,
"count": 1,
"limit": 1,
"totalResults": 1,
"items": [
{
"id": "8A34CF67453E4BDE94505476C03B1066",
"name": "IT East",
"apiName": "org-r-i",
"position": 2,
"isSiteCategory": false,
"parent": {
"id": "03C2AB780DDD442CAC90328A0CA6687E",
"name": "Region East",
"apiName": "org-r"
},
"ancestors": [
{
"id": "03C2AB780DDD442CAC90328A0CA6687E",
"name": "Region East",
"apiName": "org-r"
}
],
"allowedActions": [
"ASSET_CATEGORIZE",
"SITE_CREATE"
],
"descendantsAllowedActions": [],
"links": [
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories/8A34CF67453E4BDE94505476C03B1066",
"rel": "self",
"method": "GET",
"mediaType": "application/json"
}
]
}
],
"links": [
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(name co \"east\") AND (allowedActions eq \"SITE_CREATE\")&totalResults=true&offset=0&limit=10&orderBy=name:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "self",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(name co \"east\") AND (allowedActions eq \"SITE_CREATE\")&totalResults=true&offset=0&limit=10&orderBy=name:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "canonical",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/metadata-catalog/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories",
"rel": "describedby",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(name co \"east\") AND (allowedActions eq \"SITE_CREATE\")&totalResults=true&offset=0&limit=10&orderBy=name:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "first",
"method": "GET",
"mediaType": "application/json"
},
{
"href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories?q=(name co \"east\") AND (allowedActions eq \"SITE_CREATE\")&totalResults=true&offset=0&limit=10&orderBy=name:asc&fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions",
"rel": "last",
"method": "GET",
"mediaType": "application/json"
}
]
}