Skip to content
Open
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
21 changes: 1 addition & 20 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -67941,6 +67941,7 @@ paths:
- us3.datadoghq.com
- us5.datadoghq.com
- ap1.datadoghq.com
- ap2.datadoghq.com
- datadoghq.eu
- ddog-gov.com
subdomain:
Expand Down Expand Up @@ -85125,10 +85126,6 @@ paths:
operator: OR
permissions:
- teams_read
x-unstable: '**Note**: This endpoint is in Preview. To request access, fill
out this [form](https://www.datadoghq.com/product-preview/github-integration-for-teams/).

If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
get:
description: Returns all team connections.
operationId: ListTeamConnections
Expand Down Expand Up @@ -85208,10 +85205,6 @@ paths:
operator: OR
permissions:
- teams_read
x-unstable: '**Note**: This endpoint is in Preview. To request access, fill
out this [form](https://www.datadoghq.com/product-preview/github-integration-for-teams/).

If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
post:
description: Create multiple team connections.
operationId: CreateTeamConnections
Expand Down Expand Up @@ -85248,10 +85241,6 @@ paths:
operator: OR
permissions:
- teams_read
x-unstable: '**Note**: This endpoint is in Preview. To request access, fill
out this [form](https://www.datadoghq.com/product-preview/github-integration-for-teams/).

If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
/api/v2/team/sync:
get:
description: 'Get all team synchronization configurations.
Expand Down Expand Up @@ -85295,10 +85284,6 @@ paths:
operator: OR
permissions:
- teams_read
x-unstable: '**Note**: This endpoint is in Preview. To request access, fill
out this [form](https://www.datadoghq.com/product-preview/github-integration-for-teams/).

If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
post:
description: 'This endpoint attempts to link your existing Datadog teams with
GitHub teams by matching their names.
Expand Down Expand Up @@ -85360,10 +85345,6 @@ paths:
operator: AND
permissions:
- teams_manage
x-unstable: '**Note**: This endpoint is in Preview. To request access, fill
out this [form](https://www.datadoghq.com/product-preview/github-integration-for-teams/).

If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).'
/api/v2/team/{super_team_id}/member_teams:
get:
deprecated: true
Expand Down
28 changes: 9 additions & 19 deletions features/v2/teams.feature
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,7 @@ Feature: Teams

@generated @skip @team:DataDog/aaa-omg
Scenario: Create team connections returns "Conflict" response
Given operation "CreateTeamConnections" enabled
And new "CreateTeamConnections" request
Given new "CreateTeamConnections" request
And body with value {"data": [{"attributes": {"managed_by": "github_sync", "source": "github"}, "relationships": {"connected_team": {"data": {"id": "@GitHubOrg/team-handle", "type": "github_team"}}, "team": {"data": {"id": "87654321-4321-8765-dcba-210987654321", "type": "team"}}}, "type": "team_connection"}]}
When the request is sent
Then the response status is 409 Conflict
Expand Down Expand Up @@ -155,16 +154,14 @@ Feature: Teams

@generated @skip @team:DataDog/aaa-omg
Scenario: Delete team connections returns "No Content" response
Given operation "DeleteTeamConnections" enabled
And new "DeleteTeamConnections" request
Given new "DeleteTeamConnections" request
And body with value {"data": [{"id": "12345678-1234-5678-9abc-123456789012", "type": "team_connection"}]}
When the request is sent
Then the response status is 204 No Content

@generated @skip @team:DataDog/aaa-omg
Scenario: Delete team connections returns "Not Found" response
Given operation "DeleteTeamConnections" enabled
And new "DeleteTeamConnections" request
Given new "DeleteTeamConnections" request
And body with value {"data": [{"id": "12345678-1234-5678-9abc-123456789012", "type": "team_connection"}]}
When the request is sent
Then the response status is 404 Not Found
Expand Down Expand Up @@ -357,16 +354,14 @@ Feature: Teams

@generated @skip @team:DataDog/aaa-omg
Scenario: Get team sync configurations returns "OK" response
Given operation "GetTeamSync" enabled
And new "GetTeamSync" request
Given new "GetTeamSync" request
And request contains "filter[source]" parameter from "REPLACE.ME"
When the request is sent
Then the response status is 200 OK

@generated @skip @team:DataDog/aaa-omg
Scenario: Get team sync configurations returns "Team sync configurations not found" response
Given operation "GetTeamSync" enabled
And new "GetTeamSync" request
Given new "GetTeamSync" request
And request contains "filter[source]" parameter from "REPLACE.ME"
When the request is sent
Then the response status is 404 Team sync configurations not found
Expand All @@ -389,30 +384,26 @@ Feature: Teams

@generated @skip @team:DataDog/aaa-omg
Scenario: Link Teams with GitHub Teams returns "OK" response
Given operation "SyncTeams" enabled
And new "SyncTeams" request
Given new "SyncTeams" request
And body with value {"data": {"attributes": {"source": "github", "type": "link"}, "type": "team_sync_bulk"}}
When the request is sent
Then the response status is 200 OK

@generated @skip @team:DataDog/aaa-omg
Scenario: List team connections returns "Bad Request" response
Given operation "ListTeamConnections" enabled
And new "ListTeamConnections" request
Given new "ListTeamConnections" request
When the request is sent
Then the response status is 400 Bad Request

@generated @skip @team:DataDog/aaa-omg
Scenario: List team connections returns "OK" response
Given operation "ListTeamConnections" enabled
And new "ListTeamConnections" request
Given new "ListTeamConnections" request
When the request is sent
Then the response status is 200 OK

@generated @skip @team:DataDog/aaa-omg @with-pagination
Scenario: List team connections returns "OK" response with pagination
Given operation "ListTeamConnections" enabled
And new "ListTeamConnections" request
Given new "ListTeamConnections" request
When the request with pagination is sent
Then the response status is 200 OK

Expand Down Expand Up @@ -515,7 +506,6 @@ Feature: Teams
@replay-only @team:DataDog/aaa-omg
Scenario: Sync teams returns "OK" response
Given new "SyncTeams" request
And operation "SyncTeams" enabled
And body with value {"data": {"attributes": {"source": "github", "type": "link"}, "type": "team_sync_bulk"}}
When the request is sent
Then the response status is 200 OK
Expand Down
1 change: 1 addition & 0 deletions services/events/src/v2/EventsApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -598,6 +598,7 @@ export class EventsApi {
| "us3.datadoghq.com"
| "us5.datadoghq.com"
| "ap1.datadoghq.com"
| "ap2.datadoghq.com"
| "datadoghq.eu"
| "ddog-gov.com";
subdomain: string;
Expand Down
30 changes: 0 additions & 30 deletions services/teams/src/v2/TeamsApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -240,12 +240,6 @@ export class TeamsApiRequestFactory extends BaseAPIRequestFactory {
): Promise<RequestContext> {
const _config = _options || this.configuration;

if (!_config.unstableOperations["TeamsApi.v2.createTeamConnections"]) {
throw new Error(
"Unstable operation 'createTeamConnections' is disabled. Enable it by setting `configuration.unstableOperations['TeamsApi.v2.createTeamConnections'] = true`",
);
}

// verify required parameter 'body' is not null or undefined
if (body === null || body === undefined) {
throw new RequiredError("body", "createTeamConnections");
Expand Down Expand Up @@ -462,12 +456,6 @@ export class TeamsApiRequestFactory extends BaseAPIRequestFactory {
): Promise<RequestContext> {
const _config = _options || this.configuration;

if (!_config.unstableOperations["TeamsApi.v2.deleteTeamConnections"]) {
throw new Error(
"Unstable operation 'deleteTeamConnections' is disabled. Enable it by setting `configuration.unstableOperations['TeamsApi.v2.deleteTeamConnections'] = true`",
);
}

// verify required parameter 'body' is not null or undefined
if (body === null || body === undefined) {
throw new RequiredError("body", "deleteTeamConnections");
Expand Down Expand Up @@ -928,12 +916,6 @@ export class TeamsApiRequestFactory extends BaseAPIRequestFactory {
): Promise<RequestContext> {
const _config = _options || this.configuration;

if (!_config.unstableOperations["TeamsApi.v2.getTeamSync"]) {
throw new Error(
"Unstable operation 'getTeamSync' is disabled. Enable it by setting `configuration.unstableOperations['TeamsApi.v2.getTeamSync'] = true`",
);
}

// verify required parameter 'filterSource' is not null or undefined
if (filterSource === null || filterSource === undefined) {
throw new RequiredError("filterSource", "getTeamSync");
Expand Down Expand Up @@ -1112,12 +1094,6 @@ export class TeamsApiRequestFactory extends BaseAPIRequestFactory {
): Promise<RequestContext> {
const _config = _options || this.configuration;

if (!_config.unstableOperations["TeamsApi.v2.listTeamConnections"]) {
throw new Error(
"Unstable operation 'listTeamConnections' is disabled. Enable it by setting `configuration.unstableOperations['TeamsApi.v2.listTeamConnections'] = true`",
);
}

// Path Params
const localVarPath = "/api/v2/team/connections";

Expand Down Expand Up @@ -1465,12 +1441,6 @@ export class TeamsApiRequestFactory extends BaseAPIRequestFactory {
): Promise<RequestContext> {
const _config = _options || this.configuration;

if (!_config.unstableOperations["TeamsApi.v2.syncTeams"]) {
throw new Error(
"Unstable operation 'syncTeams' is disabled. Enable it by setting `configuration.unstableOperations['TeamsApi.v2.syncTeams'] = true`",
);
}

// verify required parameter 'body' is not null or undefined
if (body === null || body === undefined) {
throw new RequiredError("body", "syncTeams");
Expand Down