Endpoint configuration · GraphQL query

accountPolicy query

Retrieves an endpoint's AccountPolicy by its graph object id: the local account password and lockout policy in effect on a Windows or macOS endpoint, including password length, complexity, age and history requirements, and lockout thresholds. Each Endpoint has at most one, also reachable through its accountPolicy field; find them across endpoints with graphSearch on the ACCOUNT_POLICY object type. Returns a not-found error when no object has the id, and an error when the id belongs to another object type.

Response

Returns an AccountPolicyPayload!

Arguments

Name Description
id - ID! The AccountPolicy identifier.
mockOptions - MockDataInput

Options for mock data generation. Options supported: key: "PLATFORM", value: OsPlatform

example: "mockOptions": { "options": [ { "key": "PLATFORM", "value": "WINDOWS" } ] }

Example

Query

query accountPolicy(
  $id: ID!,
  $mockOptions: MockDataInput
) {
  accountPolicy(
    id: $id,
    mockOptions: $mockOptions
  ) {
    node {
      id
      orgId
      seen {
        ...SeenOnlineFragment
      }
      objectType
      objectTypeLabel
      displayName
      firstSeen
      lastSeen
      createdAt
      updatedAt
      snapshotInfo {
        ...GraphObjectSnapshotInfoFragment
      }
      endpoint {
        ...EndpointFragment
      }
      osSpecific {
        ... on AccountPolicyMacOS {
          ...AccountPolicyMacOSFragment
        }
        ... on AccountPolicyWindows {
          ...AccountPolicyWindowsFragment
        }
      }
      findings {
        ...FindingsPayloadFragment
      }
      issues {
        ...IssuesPayloadFragment
      }
      issuesSummary {
        ...IssuesSummaryFragment
      }
    }
  }
}

Variables

{
  "id": "4",
  "mockOptions": MockDataInput
}

Response

{"data": {"accountPolicy": {"node": AccountPolicy}}}