Skip to content

Commit 04f417b

Browse files
feat(firebaseappdistribution): update the API
#### firebaseappdistribution:v1alpha The following keys were added: - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.description - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.flatPath - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.httpMethod - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.id - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.parameterOrder - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.parameters.parent.description - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.parameters.parent.location - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.parameters.parent.pattern - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.parameters.parent.required - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.parameters.parent.type - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.path - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.request.$ref - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.response.$ref - resources.projects.resources.apps.resources.testCases.methods.batchUpdate.scopes - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest.description - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest.id - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest.properties.requests.description - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest.properties.requests.items.$ref - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest.properties.requests.type - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest.type - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse.description - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse.id - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse.properties.testCases.description - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse.properties.testCases.items.$ref - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse.properties.testCases.type - schemas.GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse.type - schemas.GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest.description - schemas.GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest.id - schemas.GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest.properties.allowMissing.description - schemas.GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest.properties.allowMissing.type - schemas.GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest.properties.testCase.$ref - schemas.GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest.properties.testCase.description - schemas.GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest.type The following keys were changed: - resources.projects.resources.apps.resources.testCases.methods.batchDelete.parameters.parent.description
1 parent a322847 commit 04f417b

File tree

2 files changed

+276
-4
lines changed

2 files changed

+276
-4
lines changed

discovery/firebaseappdistribution-v1alpha.json

Lines changed: 73 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -601,7 +601,7 @@
601601
],
602602
"parameters": {
603603
"parent": {
604-
"description": "Required. The parent resource where these test cases will be deleted. Format: `projects/{project_number}/apps/{app_id}`",
604+
"description": "Required. The parent resource of the test cases being deleted. Format: `projects/{project_number}/apps/{app_id}`",
605605
"location": "path",
606606
"pattern": "^projects/[^/]+/apps/[^/]+$",
607607
"required": true,
@@ -619,6 +619,34 @@
619619
"https://www.googleapis.com/auth/cloud-platform"
620620
]
621621
},
622+
"batchUpdate": {
623+
"description": "Updates multiple test cases.",
624+
"flatPath": "v1alpha/projects/{projectsId}/apps/{appsId}/testCases:batchUpdate",
625+
"httpMethod": "POST",
626+
"id": "firebaseappdistribution.projects.apps.testCases.batchUpdate",
627+
"parameterOrder": [
628+
"parent"
629+
],
630+
"parameters": {
631+
"parent": {
632+
"description": "Required. The parent resource of the test cases being updated. Format: `projects/{project_number}/apps/{app_id}`",
633+
"location": "path",
634+
"pattern": "^projects/[^/]+/apps/[^/]+$",
635+
"required": true,
636+
"type": "string"
637+
}
638+
},
639+
"path": "v1alpha/{+parent}/testCases:batchUpdate",
640+
"request": {
641+
"$ref": "GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest"
642+
},
643+
"response": {
644+
"$ref": "GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse"
645+
},
646+
"scopes": [
647+
"https://www.googleapis.com/auth/cloud-platform"
648+
]
649+
},
622650
"create": {
623651
"description": "Create a new test case.",
624652
"flatPath": "v1alpha/projects/{projectsId}/apps/{appsId}/testCases",
@@ -812,7 +840,7 @@
812840
}
813841
}
814842
},
815-
"revision": "20251012",
843+
"revision": "20251015",
816844
"rootUrl": "https://firebaseappdistribution.googleapis.com/",
817845
"schemas": {
818846
"AndroidxCrawlerOutputPoint": {
@@ -1163,6 +1191,34 @@
11631191
},
11641192
"type": "object"
11651193
},
1194+
"GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest": {
1195+
"description": "The request message for `BatchUpdateTestCase`.",
1196+
"id": "GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest",
1197+
"properties": {
1198+
"requests": {
1199+
"description": "Required. The update requests. A maximum number of 1000 test cases can be updated in one batch",
1200+
"items": {
1201+
"$ref": "GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest"
1202+
},
1203+
"type": "array"
1204+
}
1205+
},
1206+
"type": "object"
1207+
},
1208+
"GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse": {
1209+
"description": "The response message for `BatchUpdateTestCase`.",
1210+
"id": "GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse",
1211+
"properties": {
1212+
"testCases": {
1213+
"description": "The updated test cases.",
1214+
"items": {
1215+
"$ref": "GoogleFirebaseAppdistroV1alphaTestCase"
1216+
},
1217+
"type": "array"
1218+
}
1219+
},
1220+
"type": "object"
1221+
},
11661222
"GoogleFirebaseAppdistroV1alphaCancelReleaseTestResponse": {
11671223
"description": "The (empty) response message for `CancelReleaseTest`.",
11681224
"id": "GoogleFirebaseAppdistroV1alphaCancelReleaseTestResponse",
@@ -2130,6 +2186,21 @@
21302186
},
21312187
"type": "object"
21322188
},
2189+
"GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest": {
2190+
"description": "The request message for `UpdateTestCase`.",
2191+
"id": "GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest",
2192+
"properties": {
2193+
"allowMissing": {
2194+
"description": "Optional. If set to true, and the test case is not found, a new test case will be created.",
2195+
"type": "boolean"
2196+
},
2197+
"testCase": {
2198+
"$ref": "GoogleFirebaseAppdistroV1alphaTestCase",
2199+
"description": "Required. The test case to update. The test case's `name` field is used to identify the test case to update. Format: `projects/{project_number}/apps/{app_id}/testCases/{test_case_id}`"
2200+
}
2201+
},
2202+
"type": "object"
2203+
},
21332204
"GoogleProtobufEmpty": {
21342205
"description": "A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }",
21352206
"id": "GoogleProtobufEmpty",

src/apis/firebaseappdistribution/v1alpha.ts

Lines changed: 203 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -283,6 +283,24 @@ export namespace firebaseappdistribution_v1alpha {
283283
*/
284284
names?: string[] | null;
285285
}
286+
/**
287+
* The request message for `BatchUpdateTestCase`.
288+
*/
289+
export interface Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest {
290+
/**
291+
* Required. The update requests. A maximum number of 1000 test cases can be updated in one batch
292+
*/
293+
requests?: Schema$GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest[];
294+
}
295+
/**
296+
* The response message for `BatchUpdateTestCase`.
297+
*/
298+
export interface Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse {
299+
/**
300+
* The updated test cases.
301+
*/
302+
testCases?: Schema$GoogleFirebaseAppdistroV1alphaTestCase[];
303+
}
286304
/**
287305
* The (empty) response message for `CancelReleaseTest`.
288306
*/
@@ -911,6 +929,19 @@ export namespace firebaseappdistribution_v1alpha {
911929
*/
912930
usage?: string | null;
913931
}
932+
/**
933+
* The request message for `UpdateTestCase`.
934+
*/
935+
export interface Schema$GoogleFirebaseAppdistroV1alphaUpdateTestCaseRequest {
936+
/**
937+
* Optional. If set to true, and the test case is not found, a new test case will be created.
938+
*/
939+
allowMissing?: boolean | null;
940+
/**
941+
* Required. The test case to update. The test case's `name` field is used to identify the test case to update. Format: `projects/{project_number\}/apps/{app_id\}/testCases/{test_case_id\}`
942+
*/
943+
testCase?: Schema$GoogleFirebaseAppdistroV1alphaTestCase;
944+
}
914945
/**
915946
* A release of a Firebase app.
916947
*/
@@ -3438,7 +3469,7 @@ export namespace firebaseappdistribution_v1alpha {
34383469
* // Do the magic
34393470
* const res = await firebaseappdistribution.projects.apps.testCases.batchDelete(
34403471
* {
3441-
* // Required. The parent resource where these test cases will be deleted. Format: `projects/{project_number\}/apps/{app_id\}`
3472+
* // Required. The parent resource of the test cases being deleted. Format: `projects/{project_number\}/apps/{app_id\}`
34423473
* parent: 'projects/my-project/apps/my-app',
34433474
*
34443475
* // Request body metadata
@@ -3554,6 +3585,164 @@ export namespace firebaseappdistribution_v1alpha {
35543585
}
35553586
}
35563587

3588+
/**
3589+
* Updates multiple test cases.
3590+
* @example
3591+
* ```js
3592+
* // Before running the sample:
3593+
* // - Enable the API at:
3594+
* // https://console.developers.google.com/apis/api/firebaseappdistribution.googleapis.com
3595+
* // - Login into gcloud by running:
3596+
* // ```sh
3597+
* // $ gcloud auth application-default login
3598+
* // ```
3599+
* // - Install the npm module by running:
3600+
* // ```sh
3601+
* // $ npm install googleapis
3602+
* // ```
3603+
*
3604+
* const {google} = require('googleapis');
3605+
* const firebaseappdistribution = google.firebaseappdistribution('v1alpha');
3606+
*
3607+
* async function main() {
3608+
* const auth = new google.auth.GoogleAuth({
3609+
* // Scopes can be specified either as an array or as a single, space-delimited string.
3610+
* scopes: ['https://www.googleapis.com/auth/cloud-platform'],
3611+
* });
3612+
*
3613+
* // Acquire an auth client, and bind it to all future calls
3614+
* const authClient = await auth.getClient();
3615+
* google.options({auth: authClient});
3616+
*
3617+
* // Do the magic
3618+
* const res = await firebaseappdistribution.projects.apps.testCases.batchUpdate(
3619+
* {
3620+
* // Required. The parent resource of the test cases being updated. Format: `projects/{project_number\}/apps/{app_id\}`
3621+
* parent: 'projects/my-project/apps/my-app',
3622+
*
3623+
* // Request body metadata
3624+
* requestBody: {
3625+
* // request body parameters
3626+
* // {
3627+
* // "requests": []
3628+
* // }
3629+
* },
3630+
* },
3631+
* );
3632+
* console.log(res.data);
3633+
*
3634+
* // Example response
3635+
* // {
3636+
* // "testCases": []
3637+
* // }
3638+
* }
3639+
*
3640+
* main().catch(e => {
3641+
* console.error(e);
3642+
* throw e;
3643+
* });
3644+
*
3645+
* ```
3646+
*
3647+
* @param params - Parameters for request
3648+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
3649+
* @param callback - Optional callback that handles the response.
3650+
* @returns A promise if used with async/await, or void if used with a callback.
3651+
*/
3652+
batchUpdate(
3653+
params: Params$Resource$Projects$Apps$Testcases$Batchupdate,
3654+
options: StreamMethodOptions
3655+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
3656+
batchUpdate(
3657+
params?: Params$Resource$Projects$Apps$Testcases$Batchupdate,
3658+
options?: MethodOptions
3659+
): Promise<
3660+
GaxiosResponseWithHTTP2<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>
3661+
>;
3662+
batchUpdate(
3663+
params: Params$Resource$Projects$Apps$Testcases$Batchupdate,
3664+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
3665+
callback: BodyResponseCallback<Readable>
3666+
): void;
3667+
batchUpdate(
3668+
params: Params$Resource$Projects$Apps$Testcases$Batchupdate,
3669+
options:
3670+
| MethodOptions
3671+
| BodyResponseCallback<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>,
3672+
callback: BodyResponseCallback<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>
3673+
): void;
3674+
batchUpdate(
3675+
params: Params$Resource$Projects$Apps$Testcases$Batchupdate,
3676+
callback: BodyResponseCallback<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>
3677+
): void;
3678+
batchUpdate(
3679+
callback: BodyResponseCallback<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>
3680+
): void;
3681+
batchUpdate(
3682+
paramsOrCallback?:
3683+
| Params$Resource$Projects$Apps$Testcases$Batchupdate
3684+
| BodyResponseCallback<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>
3685+
| BodyResponseCallback<Readable>,
3686+
optionsOrCallback?:
3687+
| MethodOptions
3688+
| StreamMethodOptions
3689+
| BodyResponseCallback<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>
3690+
| BodyResponseCallback<Readable>,
3691+
callback?:
3692+
| BodyResponseCallback<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>
3693+
| BodyResponseCallback<Readable>
3694+
):
3695+
| void
3696+
| Promise<
3697+
GaxiosResponseWithHTTP2<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>
3698+
>
3699+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
3700+
let params = (paramsOrCallback ||
3701+
{}) as Params$Resource$Projects$Apps$Testcases$Batchupdate;
3702+
let options = (optionsOrCallback || {}) as MethodOptions;
3703+
3704+
if (typeof paramsOrCallback === 'function') {
3705+
callback = paramsOrCallback;
3706+
params = {} as Params$Resource$Projects$Apps$Testcases$Batchupdate;
3707+
options = {};
3708+
}
3709+
3710+
if (typeof optionsOrCallback === 'function') {
3711+
callback = optionsOrCallback;
3712+
options = {};
3713+
}
3714+
3715+
const rootUrl =
3716+
options.rootUrl || 'https://firebaseappdistribution.googleapis.com/';
3717+
const parameters = {
3718+
options: Object.assign(
3719+
{
3720+
url: (rootUrl + '/v1alpha/{+parent}/testCases:batchUpdate').replace(
3721+
/([^:]\/)\/+/g,
3722+
'$1'
3723+
),
3724+
method: 'POST',
3725+
apiVersion: '',
3726+
},
3727+
options
3728+
),
3729+
params,
3730+
requiredParams: ['parent'],
3731+
pathParams: ['parent'],
3732+
context: this.context,
3733+
};
3734+
if (callback) {
3735+
createAPIRequest<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>(
3736+
parameters,
3737+
callback as BodyResponseCallback<unknown>
3738+
);
3739+
} else {
3740+
return createAPIRequest<Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesResponse>(
3741+
parameters
3742+
);
3743+
}
3744+
}
3745+
35573746
/**
35583747
* Create a new test case.
35593748
* @example
@@ -4327,7 +4516,7 @@ export namespace firebaseappdistribution_v1alpha {
43274516
export interface Params$Resource$Projects$Apps$Testcases$Batchdelete
43284517
extends StandardParameters {
43294518
/**
4330-
* Required. The parent resource where these test cases will be deleted. Format: `projects/{project_number\}/apps/{app_id\}`
4519+
* Required. The parent resource of the test cases being deleted. Format: `projects/{project_number\}/apps/{app_id\}`
43314520
*/
43324521
parent?: string;
43334522

@@ -4336,6 +4525,18 @@ export namespace firebaseappdistribution_v1alpha {
43364525
*/
43374526
requestBody?: Schema$GoogleFirebaseAppdistroV1alphaBatchDeleteTestCasesRequest;
43384527
}
4528+
export interface Params$Resource$Projects$Apps$Testcases$Batchupdate
4529+
extends StandardParameters {
4530+
/**
4531+
* Required. The parent resource of the test cases being updated. Format: `projects/{project_number\}/apps/{app_id\}`
4532+
*/
4533+
parent?: string;
4534+
4535+
/**
4536+
* Request body metadata
4537+
*/
4538+
requestBody?: Schema$GoogleFirebaseAppdistroV1alphaBatchUpdateTestCasesRequest;
4539+
}
43394540
export interface Params$Resource$Projects$Apps$Testcases$Create
43404541
extends StandardParameters {
43414542
/**

0 commit comments

Comments
 (0)