List versions of a policy set
List versions of a policy set
client.zones.policySets.versions.list(stringpolicySetID, VersionListParams { zone_id, after, before, 6 more } params, RequestOptionsoptions?): VersionListResponse { items, pagination }
GET/zones/{zone_id}/policy-sets/{policy_set_id}/versions
List versions of a policy set
Parameters
policySetID: string
Returns
List versions of a policy set
import KeycardAPI from '@keycardai/api';
const client = new KeycardAPI();
const versions = await client.zones.policySets.versions.list('policy_set_id', {
zone_id: 'zone_id',
});
console.log(versions.items);{
"items": [
{
"id": "id",
"created_at": "2019-12-27T18:11:19.117Z",
"created_by": "created_by",
"manifest": {
"entries": [
{
"policy_id": "policy_id",
"policy_version_id": "policy_version_id",
"sha": "sha"
}
]
},
"manifest_sha": "manifest_sha",
"owner_type": "platform",
"policy_set_id": "policy_set_id",
"schema_version": "schema_version",
"version": 0,
"active": true,
"archived_at": "2019-12-27T18:11:19.117Z",
"archived_by": "archived_by",
"attestation": {
"attested_at": "2019-12-27T18:11:19.117Z",
"attested_by": "attested_by",
"key_id": "key_id",
"manifest_sha": "manifest_sha",
"policy_set_id": "policy_set_id",
"policy_set_version": 0,
"status": "created",
"type": "policy_set_attestation",
"v": 1,
"zone_id": "zone_id"
}
}
],
"pagination": {
"after_cursor": "x",
"before_cursor": "x",
"total_count": 0
}
}Returns Examples
{
"items": [
{
"id": "id",
"created_at": "2019-12-27T18:11:19.117Z",
"created_by": "created_by",
"manifest": {
"entries": [
{
"policy_id": "policy_id",
"policy_version_id": "policy_version_id",
"sha": "sha"
}
]
},
"manifest_sha": "manifest_sha",
"owner_type": "platform",
"policy_set_id": "policy_set_id",
"schema_version": "schema_version",
"version": 0,
"active": true,
"archived_at": "2019-12-27T18:11:19.117Z",
"archived_by": "archived_by",
"attestation": {
"attested_at": "2019-12-27T18:11:19.117Z",
"attested_by": "attested_by",
"key_id": "key_id",
"manifest_sha": "manifest_sha",
"policy_set_id": "policy_set_id",
"policy_set_version": 0,
"status": "created",
"type": "policy_set_attestation",
"v": 1,
"zone_id": "zone_id"
}
}
],
"pagination": {
"after_cursor": "x",
"before_cursor": "x",
"total_count": 0
}
}