jira.js
    Preparing search index...

    Function updatePolicy

    • Update a policy for an org

      Parameters

      • client: Client
      • parameters: {
            data?: {
                attributes: {
                    name?: string;
                    resources?: {
                        id: string;
                        links?: { ticket?: string; [key: string]: unknown };
                        meta?: {
                            atlassianAccountId?: string;
                            migrationEndDataTime?: string;
                            migrationStartDateTime?: string;
                            scheduledDate?: string;
                            [key: string]: unknown;
                        };
                        [key: string]: unknown;
                    }[];
                    rule?: { in?: string[]; [key: string]: unknown };
                    status?: "disabled" | string & {} | "enabled";
                    type: string & {} | "ip-allowlist" | "data-residency";
                    [key: string]: unknown;
                };
                id?: string;
                type: string & {}
                | "policy";
                [key: string]: unknown;
            };
            orgId: string;
            policyId: string;
        }
        • Optionaldata?: {
              attributes: {
                  name?: string;
                  resources?: {
                      id: string;
                      links?: { ticket?: string; [key: string]: unknown };
                      meta?: {
                          atlassianAccountId?: string;
                          migrationEndDataTime?: string;
                          migrationStartDateTime?: string;
                          scheduledDate?: string;
                          [key: string]: unknown;
                      };
                      [key: string]: unknown;
                  }[];
                  rule?: { in?: string[]; [key: string]: unknown };
                  status?: "disabled" | string & {} | "enabled";
                  type: string & {} | "ip-allowlist" | "data-residency";
                  [key: string]: unknown;
              };
              id?: string;
              type: string & {}
              | "policy";
              [key: string]: unknown;
          }
          • attributes: {
                name?: string;
                resources?: {
                    id: string;
                    links?: { ticket?: string; [key: string]: unknown };
                    meta?: {
                        atlassianAccountId?: string;
                        migrationEndDataTime?: string;
                        migrationStartDateTime?: string;
                        scheduledDate?: string;
                        [key: string]: unknown;
                    };
                    [key: string]: unknown;
                }[];
                rule?: { in?: string[]; [key: string]: unknown };
                status?: "disabled" | string & {} | "enabled";
                type: string & {} | "ip-allowlist" | "data-residency";
                [key: string]: unknown;
            }

            Attributes of this object

            • Optionalname?: string

              Name of this Policy

            • Optionalresources?: {
                  id: string;
                  links?: { ticket?: string; [key: string]: unknown };
                  meta?: {
                      atlassianAccountId?: string;
                      migrationEndDataTime?: string;
                      migrationStartDateTime?: string;
                      scheduledDate?: string;
                      [key: string]: unknown;
                  };
                  [key: string]: unknown;
              }[]

              List of resources Policy is associated with

            • Optionalrule?: { in?: string[]; [key: string]: unknown }

              Rule of the Policy

            • Optionalstatus?: "disabled" | string & {} | "enabled"

              Status of this Policy

            • type: string & {} | "ip-allowlist" | "data-residency"

              Type of this Policy

          • Optionalid?: string

            Unique identifier of the Policy

          • type: string & {} | "policy"

            Type of this object

        • orgId: string

          Your organization has a unique ID. Find this ID in your Atlassian Administration URL or when you create your API key.

        • policyId: string

          ID of the policy to update

      • Optionaloptions: RequestOptions

      Returns Promise<
          {
              data?: {
                  attributes: {
                      createdAt?: string;
                      id?: string;
                      metadata?: unknown;
                      name?: string;
                      ownerId?: string;
                      queryData?: unknown;
                      resources?: {
                          applicationStatus: | "failed"
                          | string & {}
                          | "enabled"
                          | "applying"
                          | "removing"
                          | "applied"
                          | "scheduled";
                          createdAt?: string;
                          id: string;
                          links?: { ticket?: (...)
                          | (...); [key: string]: unknown };
                          meta?: {
                              atlassianAccountId?: (...) | (...);
                              migrationEndDataTime?: (...) | (...);
                              migrationStartDateTime?: (...) | (...);
                              scheduledDate?: (...) | (...);
                              [key: string]: unknown;
                          };
                          metadata?: unknown;
                          type?: string;
                          updatedAt?: string;
                          [key: string]: unknown;
                      }[];
                      rule?: unknown[]
                      | { in?: string[]; [key: string]: unknown };
                      status?: "disabled" | string & {} | "enabled";
                      type:
                          | string & {}
                          | "ip-allowlist"
                          | "data-residency"
                          | "data-security"
                          | "admin-notification-settings"
                          | "generative-ai"
                          | "hipaa"
                          | "ugc-data-use-preferences"
                          | "user-join-settings-default";
                      updatedAt?: string;
                      [key: string]: unknown;
                  };
                  id: string;
                  links?: Record<string, any>;
                  message?: unknown;
                  type: string & {} | "policy";
                  [key: string]: unknown;
              };
              [key: string]: unknown;
          },
      >