← All resources

Resource

iam_policy

An IAM policy that can be attached to users

GraphQL reference →

Configuration

nameString!Required

Policy name (required)

descriptionStringOptional

Policy description

documentIAMDocument!Required

Policy document (required)

View IAMDocumentInput fields →

Input types

Fields for the structured values used in this resource’s configuration.

IAMDocumentInput

Input for a policy document

versionStringOptional

Policy document version

statements[IAMStatementInput!]!Required

Policy statements (required)

View IAMStatementInput fields →

IAMStatementInput

Input for a policy statement. Actions are validated at parse time.

relatedAccess[IAMRelatedAccessInput!]Optional

Access to related records granted through registered relationships

View IAMRelatedAccessInput fields →

conditionsIAMConditionInputOptional

Request conditions that limit when the statement applies

View IAMConditionInput fields →

filterIAMFilterInputOptional

Filter selecting the records the statement applies to; omit to apply to all matching resources

View IAMFilterInput fields →

effectEffect!Required

Allow or deny (required)

Allowed values

ALLOW — Allow the specified actions

DENY — Deny the specified actions (overrides allow)

actions[IAMAction!]!Required

Action patterns - validated IAMAction values (required)

resources[String!]!Required

Resource patterns (required)

IAMRelatedAccessInput

Access to records related to the statement's root through a registered relationship

relationshipString!Required

Registered path from the statement's root to the target records

actions[IAMAction!]!Required

Existing actions to grant through the relationship

IAMConditionInput

Request conditions that limit when a policy statement applies

networkZones[String!]Optional

Network zones the request must come from; omit for no network condition

notBeforeIAMPolicyInstantOptional

Instant before which the statement does not apply

expiresAtIAMPolicyInstantOptional

Instant from which the statement no longer applies

IAMFilterInput

Node of a conditional policy filter that selects the records a statement applies to. Kinds, comparisons and value kinds use this schema's enum values in GraphQL and in IaC policy documents alike.

kindIAMFilterKind!Required

Kind of filter node (COMPARE, MEMBER, IS_NULL, ALL or ANY); decides which other fields are required

Allowed values

COMPARE — Compare an attribute with an operand

MEMBER — Match when the attribute equals one of the listed values

IS_NULL — Match when the attribute has no value

ALL — Match when every child filter matches

ANY — Match when at least one child filter matches

attributeStringOptional

Business attribute tested by COMPARE, MEMBER and IS_NULL nodes

comparisonIAMComparisonOptional

Operator of a COMPARE node, such as EQUAL or GREATER_THAN_OR_EQUAL

Allowed values

EQUAL — Attribute equals the operand

LESS_THAN — Attribute is less than the operand

LESS_THAN_OR_EQUAL — Attribute is less than or equal to the operand

GREATER_THAN — Attribute is greater than the operand

GREATER_THAN_OR_EQUAL — Attribute is greater than or equal to the operand

operandIAMOperandInputOptional

Value a compare node compares with

View IAMOperandInput fields →

values[IAMValueInput!]Optional

Allowed values of a member node

View IAMValueInput fields →

children[IAMFilterInput!]Optional

Child filters combined by an ALL or ANY node

View IAMFilterInput fields →

IAMOperandInput

Right-hand side of a compare filter: set literal, or calendarYearsAgo with timeZone

literalIAMValueInputOptional

Fixed value to compare with; omit for a relative date

View IAMValueInput fields →

calendarYearsAgoIntOptional

Relative date: the start of the calendar year this many years before the evaluation time; requires timeZone

timeZoneStringOptional

IANA time zone used to resolve calendarYearsAgo

IAMValueInput

Typed literal value in a conditional policy filter; set exactly one value field, matching kind

kindIAMValueKind!Required

Which of the typed value fields is set

Allowed values

IDENTIFIER — A record identifier, as the record's TypeID (for example `cus_…` for order.customer)

STRING — A text value

INSTANT — A point in time

BOOLEAN — A true/false value

identifierStringOptional

Identifier value as the record's TypeID, when kind is identifier; a bare UUID is refused

stringStringOptional

Text value, when kind is string

instantIAMPolicyInstantOptional

Instant value, when kind is instant

booleanBooleanOptional

Boolean value, when kind is boolean

Read-only values

Show values
revisionString!Read only

Opaque editable-content revision. Required as expectedRevision when replacing a conditional document.

computed by the platform

idIAMPolicyID!Read only

Unique identifier

computed by the platform

createdAtString!Read only

Creation timestamp (ISO8601)

computed by the platform

updatedAtString!Read only

Last update timestamp (ISO8601)

computed by the platform

Lifecycle

The CLI can create this resource. The platform assigns its id.

When replacement is needed, the existing resource is removed before its replacement is created.