Skip to content

Set applied policy archived state

PUT
/api/v1/projects/{projectId}/policies/{appliedPolicyId}/archived
curl --request PUT \
--url https://localhost:10001/api/v1/projects/example/policies/example/archived \
--header 'Authorization: <Authorization>' \
--header 'Content-Type: application/json' \
--data '{ "archived": true }'

Archive or unarchive a specific policy applied to a project

projectId
required
string

Project ID, UUID (urn:uuid optional), or slug:my-project

appliedPolicyId
required
string

Applied policy ID, slug:my-policy, or urn:cid:bafy…

Archived state

Media type application/json
object
archived
required
boolean
Example generated
{
"archived": true
}

Updated applied policy

Media type application/json

A policy applied to a project, tracked independently of the library template it came from

object
appliedAt
string format: date-time
appliedBy
string
appliedByDid

Verifiable actor; appliedBy is the label

string
archivedAt

Set via the archive endpoint

string format: date-time
archivedBy

Set via the archive endpoint

string
archivedByDid

Verifiable actor; archivedBy is the label

string
cid

Assigned by the integrity service

string
createdAt
string format: date-time
id
integer
isArchived

Set via the archive endpoint

boolean
isReapplied
boolean
name
string
policyId

Taken from the path on create

integer
projectId

Taken from the path on create

integer
slug

Derived from name

string
status
string
subjectCid

Assigned by the integrity service

string
updatedAt
string format: date-time
Example generated
{
"name": "example"
}

Bad request - Invalid IDs or missing archived flag

Media type application/json

Error body returned by the governance endpoints; the message is human-readable and not a stable identifier

object
error
string
Example
{
"error": "Invalid request body"
}

Unauthorized - Authentication required

Media type application/json

Error body returned by the governance endpoints; the message is human-readable and not a stable identifier

object
error
string
Example
{
"error": "Invalid request body"
}

Forbidden - No project access or insufficient permissions

Media type application/json

Error body returned by the governance endpoints; the message is human-readable and not a stable identifier

object
error
string
Example
{
"error": "Invalid request body"
}

Applied policy not found

Media type application/json

Error body returned by the governance endpoints; the message is human-readable and not a stable identifier

object
error
string
Example
{
"error": "Invalid request body"
}

Internal server error

Media type application/json

Error body returned by the governance endpoints; the message is human-readable and not a stable identifier

object
error
string
Example
{
"error": "Invalid request body"
}