Skip to content

Commit 228e880

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
[FA] Fix minimum page value (#2889)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent a6a734c commit 228e880

2 files changed

Lines changed: 6 additions & 5 deletions

File tree

.generator/schemas/v2/openapi.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59714,13 +59714,14 @@ paths:
5971459714
results.'
5971559715
operationId: ListFleetAgents
5971659716
parameters:
59717-
- description: Page number for pagination (must be greater than 0).
59717+
- description: Page number for pagination (starts at 0).
5971859718
in: query
5971959719
name: page_number
5972059720
required: false
5972159721
schema:
59722+
default: 0
5972259723
format: int64
59723-
minimum: 1
59724+
minimum: 0
5972459725
type: integer
5972559726
- description: Number of results per page (must be greater than 0 and less than
5972659727
or equal to 100).

lib/datadog_api_client/v2/api/fleet_automation_api.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -693,7 +693,7 @@ def list_fleet_agents(opts = {})
693693
# Use the `page_number` and `page_size` query parameters to paginate through results.
694694
#
695695
# @param opts [Hash] the optional parameters
696-
# @option opts [Integer] :page_number Page number for pagination (must be greater than 0).
696+
# @option opts [Integer] :page_number Page number for pagination (starts at 0).
697697
# @option opts [Integer] :page_size Number of results per page (must be greater than 0 and less than or equal to 100).
698698
# @option opts [String] :sort_attribute Attribute to sort by.
699699
# @option opts [Boolean] :sort_descending Sort order (true for descending, false for ascending).
@@ -711,8 +711,8 @@ def list_fleet_agents_with_http_info(opts = {})
711711
if @api_client.config.debugging
712712
@api_client.config.logger.debug 'Calling API: FleetAutomationAPI.list_fleet_agents ...'
713713
end
714-
if @api_client.config.client_side_validation && !opts[:'page_number'].nil? && opts[:'page_number'] < 1
715-
fail ArgumentError, 'invalid value for "opts[:"page_number"]" when calling FleetAutomationAPI.list_fleet_agents, must be greater than or equal to 1.'
714+
if @api_client.config.client_side_validation && !opts[:'page_number'].nil? && opts[:'page_number'] < 0
715+
fail ArgumentError, 'invalid value for "opts[:"page_number"]" when calling FleetAutomationAPI.list_fleet_agents, must be greater than or equal to 0.'
716716
end
717717
if @api_client.config.client_side_validation && !opts[:'page_size'].nil? && opts[:'page_size'] > 100
718718
fail ArgumentError, 'invalid value for "opts[:"page_size"]" when calling FleetAutomationAPI.list_fleet_agents, must be smaller than or equal to 100.'

0 commit comments

Comments
 (0)