Skip to content

Commit

Permalink
Regenerate client from commit fcc640d of spec repo
Browse files Browse the repository at this point in the history
  • Loading branch information
ci.datadog-api-spec committed Aug 16, 2021
1 parent 9df0003 commit 263c4d6
Show file tree
Hide file tree
Showing 10 changed files with 316 additions and 9 deletions.
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.4.1.dev11",
"regenerated": "2021-08-13 15:34:31.003048",
"spec_repo_commit": "64ee0b9"
"regenerated": "2021-08-16 12:10:17.170624",
"spec_repo_commit": "fcc640d"
},
"v2": {
"apigentools_version": "1.4.1.dev11",
"regenerated": "2021-08-13 15:35:26.937747",
"spec_repo_commit": "64ee0b9"
"regenerated": "2021-08-16 12:11:08.962842",
"spec_repo_commit": "fcc640d"
}
}
}
11 changes: 11 additions & 0 deletions data/v1/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9465,6 +9465,17 @@ components:
SyntheticsGlobalVariable:
description: Synthetics global variable.
properties:
attributes:
description: Attributes of the global variable.
properties:
restricted_roles:
description: List of role identifiers that can be pulled from the Roles
API.
items:
description: UUID for a role.
type: string
type: array
type: object
description:
description: Description of the global variable.
example: Example description
Expand Down
1 change: 1 addition & 0 deletions docs/v1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -642,6 +642,7 @@ Class | Method | HTTP request | Description
- [DatadogAPIClient::V1::SyntheticsGetAPITestLatestResultsResponse](SyntheticsGetAPITestLatestResultsResponse.md)
- [DatadogAPIClient::V1::SyntheticsGetBrowserTestLatestResultsResponse](SyntheticsGetBrowserTestLatestResultsResponse.md)
- [DatadogAPIClient::V1::SyntheticsGlobalVariable](SyntheticsGlobalVariable.md)
- [DatadogAPIClient::V1::SyntheticsGlobalVariableAttributes](SyntheticsGlobalVariableAttributes.md)
- [DatadogAPIClient::V1::SyntheticsGlobalVariableParseTestOptions](SyntheticsGlobalVariableParseTestOptions.md)
- [DatadogAPIClient::V1::SyntheticsGlobalVariableParseTestOptionsType](SyntheticsGlobalVariableParseTestOptionsType.md)
- [DatadogAPIClient::V1::SyntheticsGlobalVariableParserType](SyntheticsGlobalVariableParserType.md)
Expand Down
2 changes: 2 additions & 0 deletions docs/v1/SyntheticsGlobalVariable.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |
| **attributes** | [**SyntheticsGlobalVariableAttributes**](SyntheticsGlobalVariableAttributes.md) | | [optional] |
| **description** | **String** | Description of the global variable. | |
| **id** | **String** | Unique identifier of the global variable. | [optional][readonly] |
| **name** | **String** | Name of the global variable. | |
Expand All @@ -18,6 +19,7 @@
require 'datadog_api_client/v1'

instance = DatadogAPIClient::V1::SyntheticsGlobalVariable.new(
attributes: null,
description: Example description,
id: null,
name: MY_VARIABLE,
Expand Down
18 changes: 18 additions & 0 deletions docs/v1/SyntheticsGlobalVariableAttributes.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# DatadogAPIClient::V1::SyntheticsGlobalVariableAttributes

## Properties

| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |
| **restricted_roles** | **Array<String>** | List of role identifiers that can be pulled from the Roles API. | [optional] |

## Example

```ruby
require 'datadog_api_client/v1'

instance = DatadogAPIClient::V1::SyntheticsGlobalVariableAttributes.new(
restricted_roles: null
)
```

8 changes: 4 additions & 4 deletions features/v1/synthetics.feature
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,14 @@ Feature: Synthetics
@generated @skip
Scenario: Create a global variable returns "Invalid request" response
Given new "CreateGlobalVariable" request
And body with value {"description": "Example description", "name": "MY_VARIABLE", "parse_test_options": {"field": "content-type", "parser": {"type": "regex", "value": ".*"}, "type": "http_body"}, "parse_test_public_id": "abc-def-123", "tags": ["team:front", "test:workflow-1"], "value": {"secure": true, "value": "value"}}
And body with value {"attributes": {"restricted_roles": [null]}, "description": "Example description", "name": "MY_VARIABLE", "parse_test_options": {"field": "content-type", "parser": {"type": "regex", "value": ".*"}, "type": "http_body"}, "parse_test_public_id": "abc-def-123", "tags": ["team:front", "test:workflow-1"], "value": {"secure": true, "value": "value"}}
When the request is sent
Then the response status is 400 Invalid request

@generated @skip
Scenario: Create a global variable returns "OK" response
Given new "CreateGlobalVariable" request
And body with value {"description": "Example description", "name": "MY_VARIABLE", "parse_test_options": {"field": "content-type", "parser": {"type": "regex", "value": ".*"}, "type": "http_body"}, "parse_test_public_id": "abc-def-123", "tags": ["team:front", "test:workflow-1"], "value": {"secure": true, "value": "value"}}
And body with value {"attributes": {"restricted_roles": [null]}, "description": "Example description", "name": "MY_VARIABLE", "parse_test_options": {"field": "content-type", "parser": {"type": "regex", "value": ".*"}, "type": "http_body"}, "parse_test_public_id": "abc-def-123", "tags": ["team:front", "test:workflow-1"], "value": {"secure": true, "value": "value"}}
When the request is sent
Then the response status is 200 OK

Expand Down Expand Up @@ -191,15 +191,15 @@ Feature: Synthetics
Scenario: Edit a global variable returns "Invalid request" response
Given new "EditGlobalVariable" request
And request contains "variable_id" parameter from "<PATH>"
And body with value {"description": "Example description", "name": "MY_VARIABLE", "parse_test_options": {"field": "content-type", "parser": {"type": "regex", "value": ".*"}, "type": "http_body"}, "parse_test_public_id": "abc-def-123", "tags": ["team:front", "test:workflow-1"], "value": {"secure": true, "value": "value"}}
And body with value {"attributes": {"restricted_roles": [null]}, "description": "Example description", "name": "MY_VARIABLE", "parse_test_options": {"field": "content-type", "parser": {"type": "regex", "value": ".*"}, "type": "http_body"}, "parse_test_public_id": "abc-def-123", "tags": ["team:front", "test:workflow-1"], "value": {"secure": true, "value": "value"}}
When the request is sent
Then the response status is 400 Invalid request

@generated @skip
Scenario: Edit a global variable returns "OK" response
Given new "EditGlobalVariable" request
And request contains "variable_id" parameter from "<PATH>"
And body with value {"description": "Example description", "name": "MY_VARIABLE", "parse_test_options": {"field": "content-type", "parser": {"type": "regex", "value": ".*"}, "type": "http_body"}, "parse_test_public_id": "abc-def-123", "tags": ["team:front", "test:workflow-1"], "value": {"secure": true, "value": "value"}}
And body with value {"attributes": {"restricted_roles": [null]}, "description": "Example description", "name": "MY_VARIABLE", "parse_test_options": {"field": "content-type", "parser": {"type": "regex", "value": ".*"}, "type": "http_body"}, "parse_test_public_id": "abc-def-123", "tags": ["team:front", "test:workflow-1"], "value": {"secure": true, "value": "value"}}
When the request is sent
Then the response status is 200 OK

Expand Down
1 change: 1 addition & 0 deletions lib/datadog_api_client/v1.rb
Original file line number Diff line number Diff line change
Expand Up @@ -426,6 +426,7 @@
require 'datadog_api_client/v1/models/synthetics_get_api_test_latest_results_response'
require 'datadog_api_client/v1/models/synthetics_get_browser_test_latest_results_response'
require 'datadog_api_client/v1/models/synthetics_global_variable'
require 'datadog_api_client/v1/models/synthetics_global_variable_attributes'
require 'datadog_api_client/v1/models/synthetics_global_variable_parse_test_options'
require 'datadog_api_client/v1/models/synthetics_global_variable_parse_test_options_type'
require 'datadog_api_client/v1/models/synthetics_global_variable_parser_type'
Expand Down
11 changes: 10 additions & 1 deletion lib/datadog_api_client/v1/models/synthetics_global_variable.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@
module DatadogAPIClient::V1
# Synthetics global variable.
class SyntheticsGlobalVariable
attr_accessor :attributes

# Description of the global variable.
attr_accessor :description

Expand All @@ -41,6 +43,7 @@ class SyntheticsGlobalVariable
# Attribute mapping from ruby-style variable name to JSON key.
def self.attribute_map
{
:'attributes' => :'attributes',
:'description' => :'description',
:'id' => :'id',
:'name' => :'name',
Expand All @@ -59,6 +62,7 @@ def self.acceptable_attributes
# Attribute type mapping.
def self.openapi_types
{
:'attributes' => :'SyntheticsGlobalVariableAttributes',
:'description' => :'String',
:'id' => :'String',
:'name' => :'String',
Expand Down Expand Up @@ -90,6 +94,10 @@ def initialize(attributes = {})
h[k.to_sym] = v
}

if attributes.key?(:'attributes')
self.attributes = attributes[:'attributes']
end

if attributes.key?(:'description')
self.description = attributes[:'description']
end
Expand Down Expand Up @@ -159,6 +167,7 @@ def valid?
def ==(o)
return true if self.equal?(o)
self.class == o.class &&
attributes == o.attributes &&
description == o.description &&
id == o.id &&
name == o.name &&
Expand All @@ -177,7 +186,7 @@ def eql?(o)
# Calculates hash code according to all attributes.
# @return [Integer] Hash code
def hash
[description, id, name, parse_test_options, parse_test_public_id, tags, value].hash
[attributes, description, id, name, parse_test_options, parse_test_public_id, tags, value].hash
end

# Builds the object from hash
Expand Down
Loading

0 comments on commit 263c4d6

Please sign in to comment.