Update enabled flag of a policy

post

/epm/rest/v1/policies/{policyId}/updateEnabledFlag

Request

Supported Media Types
Path Parameters
Body ()
Specifies whether the policy should be enabled or disabled.
Root Schema : Parameter to enable or disable a policy
Type: object
Show Source
Back to Top

Response

Supported Media Types

200 Response

Policy's enabled flag updated successfully
Body ()
Root Schema : Policy
Type: object
Show Source
Nested Schema : allowedActions
Type: array
Unique Items Required: true
Show Source
  • Allowed Values: [ "DELETE_NODE", "ADD_NODE", "REMOVE_NODE", "INSERT_NODE", "MOVE_NODE", "RENAME_NODE", "UPDATE_NODE_PROP", "UPDATE_REL_PROP", "UPDATE_DESCRIPTION", "REORDER_NODE", "CLEAR_PROP", "RESET_PRIMARY_LOCATION" ]
Nested Schema : IdNameDescription
Type: object
Show Source
Nested Schema : configuredProperties
Type: array
Unique Items Required: true
Show Source
Nested Schema : User
Type: object
Show Source
Nested Schema : JsonNode
Type: object
Nested Schema : invitees
Type: array
Show Source
Nested Schema : inviteeSummary
Type: array
Show Source
Nested Schema : notifyOnStatusesChanged
Type: array
Unique Items Required: true
Show Source
  • Allowed Values: [ "DRAFT", "IN_FLIGHT", "PULLED_BACK", "PUSHED_BACK", "COMPLETED", "REJECTED", "WITHDRAWN", "RECALLED", "BLOCKED", "CONSOLIDATED", "FUTURE_DATED" ]
Nested Schema : requestTypes
Type: array
Unique Items Required: true
Show Source
  • Allowed Values: [ "DEFINED", "INSTRUCTIVE", "INTERACTIVE", "MEMBERSHIP", "NOTIFICATION", "REMEDIATION", "SUBSCRIPTION", "CONSOLIDATION", "IMPORT", "LOAD" ]
Nested Schema : artifactAssignments
Type: array
Show Source
Nested Schema : associatedRoles
Type: array
Show Source
Nested Schema : emailAddresses
Type: array
Show Source
Nested Schema : Preferences
Type: object
Show Source
Nested Schema : ArtifactAssignment
Type: object
Show Source
Nested Schema : Artifact
Type: object
Show Source
Nested Schema : Role
Type: object
Show Source
Nested Schema : TimeZone
Type: object
Show Source
Nested Schema : Invitee
Type: object
Show Source
Nested Schema : Group
Type: object
Show Source
Nested Schema : associatedUsers
Type: array
Show Source

400 Response

Error in body

403 Response

Forbidden
Back to Top

Examples

The following example shows how to enable or disable a policy by using a POST request on the REST resource using cURL.

cURL Command

curl --user epm_cloud_user -X POST -H 'Content-Type: application/json' @example_request_payload.json https://servername.fa.us2.oraclecloud.com/epm/rest/v1/policies/322df024-a20a-4367-b7c1-348b15409189/updateEnabledFlag

Example of Request Body

The following shows an example of the request body in JSON format. The value can be either true or false.

    {
        "enabled": true
    }

Example of Response Body

The following shows an example of the response body in JSON format.

    {
        "id": "322df024-a20a-4367-b7c1-348b15409189",
        "name": "Approval",
        "description": "Approval policy for Departments",
        "policyType": "APPROVAL",
        "policyLevel": "APPLICATION",
        "application": {
            "id": "64a99b9c-a13e-4509-9513-2d086da4ff00",
            "name": "Departments",
            "description": "Departments App"
        },
        "createdBy": "Doug Cosby",
        "timeCreated": "2024-09-03T16:30:47.727Z",
        "modifiedBy": "Doug Cosby",
        "timeModified": "2024-09-27T14:05:05.570Z",
        "enabled": true,
        "valid": true,
        "inviteeSummary": [
            {
                "id": "0ec452de-1cfa-4a0e-87d0-376fffdb0351",
                "name": "Accounting",
                "description": "desc"
            },
            {
                "id": "1ba600a7-1997-4784-9163-f46510533642",
                "name": "Barry Dylan",
                "description": null
            },
            {
                "id": "f52e4517-7e07-4ea5-a75b-728ef0a54530",
                "name": "GroupA",
                "description": "desc"
            },
            {
                "id": "45b96c8a-7e8a-4e24-8279-9f2b88118e29",
                "name": "Doug Cosby",
                "description": null
            }
        ],
        "processingType": "PARALLEL",
        "allInviteesMustApprove": true,
        "numberOfApprovalsRequired": 0,
        "submitterAutoApproves": false,
        "reminderNotification": 0,
        "approvalEscalation": 0,
        "daysUntilOverdue": 0,
        "allowEnrichment": false,
        "policyOrder": 1,
        "ownershipPropertyId": null,
        "managementHierarchyNodeSet": null,
        "fulfillmentType": null,
        "fulfillmentLevels": 0,
        "fulfillmentExpression": null,
        "allowAllActions": true,
        "allowedActions": [],
        "expression": {
            "statements": [
                {
                    "type": "return",
                    "expression": {
                        "type": "booleanLiteral",
                        "value": false
                    }
                }
            ]
        },
        "propertyFilterConfigurationType": "INCLUDE",
        "configuredProperties": [
            {
                "id": "24021227-c4d9-4190-b698-9ebfed7f8015",
                "name": "Alias",
                "links": [
                    {
                        "rel": "self",
                        "href": "https://servername.fa.us2.oraclecloud.com/epm/rest/v1/applications/24021227-c4d9-4190-b698-9ebfed7f8015"
                    }
                ]
            },
            {
                "id": "fb8aad87-7c0d-4d32-b523-7f807121408a",
                "name": "Aggregation Weight",
                "links": [
                    {
                        "rel": "self",
                        "href": "https://servername.fa.us2.oraclecloud.com/epm/rest/v1/applications/fb8aad87-7c0d-4d32-b523-7f807121408a"
                    }
                ]
            }
        ],
        "requestTypes": [],
        "allowAllRequestTypes": true,
        "links": [
            {
                "rel": "self",
                "href": "https://servername.fa.us2.oraclecloud.com/epm/rest/v1/applications/64a99b9c-a13e-4509-9513-2d086da4ff00/policies/322df024-a20a-4367-b7c1-348b15409189"
            },
            {
                "rel": "updateEnabledFlag",
                "href": "https://servername.fa.us2.oraclecloud.com/epm/rest/v1/policies/322df024-a20a-4367-b7c1-348b15409189/updateEnabledFlag",
                "method": "POST"
            }
        ]
    }
Back to Top