Skip to main content

Update Policy

PUThttps://api.eu1.coralogix.com/mgmt/openapi/5/dataplans/policies/v1

Updates an existing data policy.

Authorizations

Authorizationstringheaderrequired
API key authentication

Request​

Body

application/json

This data structue is used to update an existing policy.

    oneOf
    object

    Rule.

    Archive retention.

    description#string

    Optional free-text description of the policy's purpose. Only Latin-1 characters are accepted.

    Possible values: <= 255 characters, Value must match regular expression ^[\x00-\xFF]*$

    Example: My Policy Description
    enabled#boolean

    Indicates whether the policy should be actively evaluated and applied.

    Example: true
    id#stringrequired

    Unique identifier of the policy to update.

    Possible values: >= 36 characters and <= 36 characters, Value must match regular expression ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$

    Example: 3dc02998-0b50-4ea8-b68a-4779d716fa1f

    Log rules for a policy. Set severities or dpxlExpression, not both.

    name#string

    Human-readable name for the policy. Only Latin-1 characters are accepted.

    Possible values: non-empty and <= 255 characters, Value must match regular expression ^[\x00-\xFF]*$

    Example: My Policy
    priority#quota.v1.Priority

    TCO priority level assigned to a policy, controlling how data is routed and archived.

    Possible values: [PRIORITY_TYPE_UNSPECIFIED, PRIORITY_TYPE_BLOCK, PRIORITY_TYPE_LOW, PRIORITY_TYPE_MEDIUM, PRIORITY_TYPE_HIGH]

    Priority override.

    Log rules for a policy. Set severities or dpxlExpression, not both.

    Span rules.

    Rule.

    List of data targets/destinations to which this policy routes data.

    Possible values: <= 5

Response

application/json

This data structue is obtained when updating a policy.

    policy#objectrequired

    A policy is a set of rules that define the behavior of the Coralogix system for a specific company.

    oneOf
    object

    Rule.

    Archive retention.

    policy.companyId#int32required

    Internal Coralogix company/team identifier that owns this policy.

    Possible values: >= 0 and <= 2147483647

    Example: 1234
    policy.createdAt#string

    Timestamp (RFC 3339) when the policy was created.

    Possible values: <= 64 characters, Value must match regular expression ^[\s\S]*$

    Example: 2021-01-01T00:00:00.000Z
    policy.deleted#booleanrequired

    Soft-delete marker; when true the policy has been deleted and is no longer applied.

    Example: false
    policy.description#string

    Optional free-text description of the policy's purpose. Only Latin-1 characters are accepted. A policy that POST /dataplans/policies/v1 created without a description returns an empty string. A policy that an atomic overwrite created without a description can return none.

    Possible values: <= 255 characters, Value must match regular expression ^[\x00-\xFF]*$

    Example: My Policy Description
    policy.enabled#booleanrequired

    Indicates whether the policy is actively evaluated and applied. A create or atomic-overwrite request sets it as the opposite of its disabled value; PUT /dataplans/policies/v1 sets enabled directly.

    Example: true
    policy.id#stringrequired

    Unique identifier for the policy. The service sets it, and an overwrite that changes the policies gives every policy a new id.

    Possible values: >= 36 characters and <= 36 characters, Value must match regular expression ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$

    Example: 3dc02998-0b50-4ea8-b68a-4779d716fa1f

    Log rules for a policy. Set severities or dpxlExpression, not both.

    policy.name#stringrequired

    Human-readable name for the policy. Only Latin-1 characters are accepted.

    Possible values: non-empty and <= 255 characters, Value must match regular expression ^[\x00-\xFF]*$

    Example: My Policy
    policy.order#int32required

    Ordering priority that determines the sequence in which policies are evaluated. Can be negative for policies placed first. An overwrite sets it to the position of the policy in the request, starting at 1.

    Possible values: >= -2147483648 and <= 2147483647

    Example: 1
    policy.priority#quota.v1.Priorityrequired

    TCO priority level assigned to a policy, controlling how data is routed and archived.

    Possible values: [PRIORITY_TYPE_UNSPECIFIED, PRIORITY_TYPE_BLOCK, PRIORITY_TYPE_LOW, PRIORITY_TYPE_MEDIUM, PRIORITY_TYPE_HIGH]

    Priority override.

    The priority currently in effect, from the quota usage of the team against the usage tiers. Get Company Policies returns it for an enabled policy with a quota-based override.

    Log rules for a policy. Set severities or dpxlExpression, not both.

    Span rules.

    Rule.

    List of data targets/destinations to which this policy routes data. A log policy created without targets has one target: the logs dataset of the default dataspace, with the priority and the override of the policy. A span policy has one spans target. A RUM policy has none.

    Possible values: <= 5

    policy.updatedAt#string

    Timestamp (RFC 3339) when the policy was last updated.

    Possible values: <= 64 characters, Value must match regular expression ^[\s\S]*$

    Example: 2021-01-01T00:00:00.000Z