Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[monitors] Deprecate locked property and clarify documentation for restricted_roles #888

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .apigentools-info
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
"spec_versions": {
"v1": {
"apigentools_version": "1.6.2",
"regenerated": "2022-03-15 09:31:12.853869",
"spec_repo_commit": "80288098"
"regenerated": "2022-03-16 14:22:15.397892",
"spec_repo_commit": "a7afd4c8"
},
"v2": {
"apigentools_version": "1.6.2",
"regenerated": "2022-03-15 09:31:12.864935",
"spec_repo_commit": "80288098"
"regenerated": "2022-03-16 14:22:15.412827",
"spec_repo_commit": "a7afd4c8"
}
}
}
19 changes: 14 additions & 5 deletions .generator/schemas/v1/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5619,8 +5619,12 @@ components:
example: avg(last_5m):sum:system.net.bytes_rcvd{host:host0} > 100
type: string
restricted_roles:
description: A list of role identifiers that can be pulled from the Roles
API. Cannot be used with `locked` option.
description: A list of unique role identifiers to define which roles are
allowed to edit the monitor. Editing a monitor includes any updates to
the monitor configuration, monitor deletion, and muting of the monitor
for any amount of time. Roles unique identifiers can be pulled from the
[Roles API](https://docs.datadoghq.com/api/latest/roles/#list-roles) in
the `data.id` field.
items:
description: A role UUID.
type: string
Expand Down Expand Up @@ -5945,8 +5949,9 @@ components:
- If `False`, `[Triggered] Monitor Title`'
type: boolean
locked:
deprecated: true
description: Whether or not the monitor is locked (only editable by creator
and admins).
and admins). Use `restricted_roles` instead.
type: boolean
min_failure_duration:
default: 0
Expand Down Expand Up @@ -6553,8 +6558,12 @@ components:
description: The monitor query.
type: string
restricted_roles:
description: A list of role identifiers that can be pulled from the Roles
API. Cannot be used with `locked` option.
description: A list of unique role identifiers to define which roles are
allowed to edit the monitor. Editing a monitor includes any updates to
the monitor configuration, monitor deletion, and muting of the monitor
for any amount of time. Roles unique identifiers can be pulled from the
[Roles API](https://docs.datadoghq.com/api/latest/roles/#list-roles) in
the `data.id` field.
items:
description: A role UUID.
type: string
Expand Down
19 changes: 10 additions & 9 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ components:
format: int64
type: integer
RoleID:
description: The ID of the role.
description: The unique identifier of the role.
in: path
name: role_id
required: true
Expand Down Expand Up @@ -4851,7 +4851,7 @@ components:
description: Relationship to role object.
properties:
id:
description: ID of the role.
description: The unique identifier of the role.
example: 3653d3c6-0c75-11ea-ad28-fb5701eabc7d
type: string
type:
Expand All @@ -4861,7 +4861,7 @@ components:
description: Relationship to roles.
properties:
data:
description: An array containing type and ID of a role.
description: An array containing type and the unique identifier of a role.
items:
$ref: '#/components/schemas/RelationshipToRoleData'
type: array
Expand Down Expand Up @@ -4934,7 +4934,7 @@ components:
attributes:
$ref: '#/components/schemas/RoleAttributes'
id:
description: ID of the role.
description: The unique identifier of the role.
type: string
relationships:
$ref: '#/components/schemas/RoleResponseRelationships'
Expand All @@ -4957,7 +4957,8 @@ components:
readOnly: true
type: string
name:
description: Name of the role.
description: The name of the role. The name is neither unique nor a stable
identifier of the role.
type: string
user_count:
description: Number of users with that role.
Expand Down Expand Up @@ -5047,7 +5048,7 @@ components:
attributes:
$ref: '#/components/schemas/RoleCreateAttributes'
id:
description: ID of the role.
description: The unique identifier of the role.
type: string
relationships:
$ref: '#/components/schemas/RoleResponseRelationships'
Expand Down Expand Up @@ -5099,7 +5100,7 @@ components:
attributes:
$ref: '#/components/schemas/RoleUpdateAttributes'
id:
description: ID of the role.
description: The unique identifier of the role.
example: 00000000-0000-1111-0000-000000000000
type: string
type:
Expand Down Expand Up @@ -5129,7 +5130,7 @@ components:
attributes:
$ref: '#/components/schemas/RoleUpdateAttributes'
id:
description: ID of the role.
description: The unique identifier of the role.
type: string
relationships:
$ref: '#/components/schemas/RoleResponseRelationships'
Expand Down Expand Up @@ -9437,7 +9438,7 @@ paths:
type: safe
/api/v2/roles:
get:
description: Returns all roles, including their names and IDs.
description: Returns all roles, including their names and their unique identifiers.
operationId: ListRoles
parameters:
- $ref: '#/components/parameters/PageSize'
Expand Down
2 changes: 1 addition & 1 deletion src/datadog_api_client/v1/model/monitor.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/datadog_api_client/v1/model/monitor_options.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 11 additions & 11 deletions src/datadog_api_client/v2/api/roles_api.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/datadog_api_client/v2/model/relationship_to_roles.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/datadog_api_client/v2/model/role.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/datadog_api_client/v2/model/role_attributes.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/datadog_api_client/v2/model/role_update_data.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.