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

Document missing parameters #1992

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.6",
"regenerated": "2023-10-23 18:35:28.676168",
"spec_repo_commit": "696abec0"
"regenerated": "2023-10-24 18:01:02.933140",
"spec_repo_commit": "7e490450"
},
"v2": {
"apigentools_version": "1.6.6",
"regenerated": "2023-10-23 18:35:28.690762",
"spec_repo_commit": "696abec0"
"regenerated": "2023-10-24 18:01:02.950105",
"spec_repo_commit": "7e490450"
}
}
}
78 changes: 76 additions & 2 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@ components:
headers: {}
links: {}
parameters:
APIKeyCategoryParameter:
description: Filter API keys by category.
in: query
name: filter[category]
required: false
schema:
type: string
APIKeyFilterCreatedAtEndParameter:
description: Only include API keys created on or before the specified date.
in: query
Expand Down Expand Up @@ -59,6 +66,13 @@ components:
schema:
example: created_by,modified_by
type: string
APIKeyReadConfigReadEnabledParameter:
description: Filter API keys by remote config read enabled status.
in: query
name: filter[remote_config_read_enabled]
required: false
schema:
type: boolean
APIKeysSortParameter:
description: 'API key attribute used to sort results. Sort order is ascending

Expand Down Expand Up @@ -17744,6 +17758,41 @@ components:
required:
- data
type: object
TeamsField:
description: Supported teams field.
enum:
- id
- name
- handle
- summary
- description
- avatar
- banner
- visible_modules
- hidden_modules
- created_at
- modified_at
- user_count
- link_count
- team_links
- user_team_permissions
type: string
x-enum-varnames:
- ID
- NAME
- HANDLE
- SUMMARY
- DESCRIPTION
- AVATAR
- BANNER
- VISIBLE_MODULES
- HIDDEN_MODULES
- CREATED_AT
- MODIFIED_AT
- USER_COUNT
- LINK_COUNT
- TEAM_LINKS
- USER_TEAM_PERMISSIONS
TeamsResponse:
description: Response with multiple teams
properties:
Expand Down Expand Up @@ -18378,8 +18427,8 @@ components:
description: User team permission attributes
properties:
permissions:
description: Object of team permission actions and boolean values indicating
of the currently logged in user can perform them on this team
description: Object of team permission actions and boolean values that a
logged in user can perform on this team.
readOnly: true
type: object
type: object
Expand Down Expand Up @@ -18634,6 +18683,8 @@ paths:
- $ref: '#/components/parameters/APIKeyFilterModifiedAtStartParameter'
- $ref: '#/components/parameters/APIKeyFilterModifiedAtEndParameter'
- $ref: '#/components/parameters/APIKeyIncludeParameter'
- $ref: '#/components/parameters/APIKeyReadConfigReadEnabledParameter'
- $ref: '#/components/parameters/APIKeyCategoryParameter'
responses:
'200':
content:
Expand Down Expand Up @@ -19067,6 +19118,7 @@ paths:
- $ref: '#/components/parameters/ApplicationKeyFilterParameter'
- $ref: '#/components/parameters/ApplicationKeyFilterCreatedAtStartParameter'
- $ref: '#/components/parameters/ApplicationKeyFilterCreatedAtEndParameter'
- $ref: '#/components/parameters/ApplicationKeyIncludeParameter'
responses:
'200':
content:
Expand Down Expand Up @@ -20106,6 +20158,7 @@ paths:
- $ref: '#/components/parameters/ApplicationKeyFilterParameter'
- $ref: '#/components/parameters/ApplicationKeyFilterCreatedAtStartParameter'
- $ref: '#/components/parameters/ApplicationKeyFilterCreatedAtEndParameter'
- $ref: '#/components/parameters/ApplicationKeyIncludeParameter'
responses:
'200':
content:
Expand Down Expand Up @@ -25055,6 +25108,12 @@ paths:
required: false
schema:
type: string
- description: Filter all roles by the given list of role IDs.
in: query
name: filter[id]
required: false
schema:
type: string
responses:
'200':
content:
Expand Down Expand Up @@ -27775,12 +27834,14 @@ paths:
- description: Specifies the order of the returned teams
in: query
name: sort
required: false
schema:
$ref: '#/components/schemas/ListTeamsSort'
- description: 'Included related resources optionally requested. Allowed enum
values: `team_links, user_team_permissions`'
in: query
name: include
required: false
schema:
items:
$ref: '#/components/schemas/ListTeamsInclude'
Expand All @@ -27789,13 +27850,24 @@ paths:
member
in: query
name: filter[keyword]
required: false
schema:
type: string
- description: When true, only returns teams the current user belongs to
in: query
name: filter[me]
required: false
schema:
type: boolean
- description: List of fields that need to be fetched.
explode: false
in: query
name: fields[team]
required: false
schema:
items:
$ref: '#/components/schemas/TeamsField'
type: array
responses:
'200':
content:
Expand Down Expand Up @@ -28210,11 +28282,13 @@ paths:
- description: Specifies the order of returned team memberships
in: query
name: sort
required: false
schema:
$ref: '#/components/schemas/GetTeamMembershipsSort'
- description: Search query, can be user email or name
in: query
name: filter[keyword]
required: false
schema:
type: string
responses:
Expand Down
30 changes: 30 additions & 0 deletions examples/v2/teams/ListTeams_3429963470.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
// Get all teams with fields_team parameter returns "OK" response

import com.datadog.api.client.ApiClient;
import com.datadog.api.client.ApiException;
import com.datadog.api.client.v2.api.TeamsApi;
import com.datadog.api.client.v2.api.TeamsApi.ListTeamsOptionalParameters;
import com.datadog.api.client.v2.model.TeamsField;
import com.datadog.api.client.v2.model.TeamsResponse;
import java.util.Arrays;

public class Example {
public static void main(String[] args) {
ApiClient defaultClient = ApiClient.getDefaultApiClient();
TeamsApi apiInstance = new TeamsApi(defaultClient);

try {
TeamsResponse result =
apiInstance.listTeams(
new ListTeamsOptionalParameters()
.fieldsTeam(Arrays.asList(TeamsField.ID, TeamsField.NAME, TeamsField.HANDLE)));
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling TeamsApi#listTeams");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Loading
Loading