@maxim_mazurok/gapi.client.customsearch-v1 0.2.20260317 → 0.2.20260607
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.d.ts +11 -11
- package/package.json +1 -1
- package/readme.md +17 -0
package/index.d.ts
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
// This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
|
|
10
10
|
// In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
|
|
11
11
|
// Generated from: https://customsearch.googleapis.com/$discovery/rest?version=v1
|
|
12
|
-
// Revision:
|
|
12
|
+
// Revision: 20260607
|
|
13
13
|
|
|
14
14
|
/// <reference types="gapi.client" />
|
|
15
15
|
|
|
@@ -26,7 +26,7 @@ declare namespace gapi.client {
|
|
|
26
26
|
namespace search {
|
|
27
27
|
interface Promotion {
|
|
28
28
|
/** An array of block objects for this promotion. */
|
|
29
|
-
bodyLines?:
|
|
29
|
+
bodyLines?: {
|
|
30
30
|
/** The block object's text in HTML, if it has text. */
|
|
31
31
|
htmlTitle?: string;
|
|
32
32
|
/** The anchor text of the block object's link, if it has a link. */
|
|
@@ -35,7 +35,7 @@ declare namespace gapi.client {
|
|
|
35
35
|
title?: string;
|
|
36
36
|
/** The URL of the block object's link, if it has one. */
|
|
37
37
|
url?: string;
|
|
38
|
-
}
|
|
38
|
+
}[];
|
|
39
39
|
/** An abridged version of this search's result URL, e.g. www.example.com. */
|
|
40
40
|
displayLink?: string;
|
|
41
41
|
/** The title of the promotion, in HTML. */
|
|
@@ -89,14 +89,14 @@ declare namespace gapi.client {
|
|
|
89
89
|
/** A unique identifier for the type of current object. For this API, it is `customsearch#result.` */
|
|
90
90
|
kind?: string;
|
|
91
91
|
/** Encapsulates all information about refinement labels. */
|
|
92
|
-
labels?:
|
|
92
|
+
labels?: {
|
|
93
93
|
/** The display name of a refinement label. This is the name you should display in your user interface. */
|
|
94
94
|
displayName?: string;
|
|
95
95
|
/** Refinement label and the associated refinement operation. */
|
|
96
96
|
label_with_op?: string;
|
|
97
97
|
/** The name of a refinement label, which you can use to refine searches. Don't display this in your user interface; instead, use displayName. */
|
|
98
98
|
name?: string;
|
|
99
|
-
}
|
|
99
|
+
}[];
|
|
100
100
|
/** The full URL to which the search result is pointing, e.g. http://www.example.com/foo/bar. */
|
|
101
101
|
link?: string;
|
|
102
102
|
/** The MIME type of the search result. */
|
|
@@ -120,7 +120,7 @@ declare namespace gapi.client {
|
|
|
120
120
|
/** Query metadata for the previous, current, and next pages of results. */
|
|
121
121
|
queries?: {
|
|
122
122
|
/** Metadata representing the next page of results, if applicable. */
|
|
123
|
-
nextPage?:
|
|
123
|
+
nextPage?: {
|
|
124
124
|
/** Number of search results returned in this set. */
|
|
125
125
|
count?: number;
|
|
126
126
|
/** Restricts search results to documents originating in a particular country. You may use [Boolean operators](https://developers.google.com/custom-search/docs/json_api_reference#BooleanOrSearch) in the `cr` parameter's value. Google WebSearch determines the country of a document by analyzing the following: * The top-level domain (TLD) of the document's URL. * The geographic location of the web server's IP address. See [Country (cr) Parameter Values](https://developers.google.com/custom-search/docs/json_api_reference#countryCollections) for a list of valid values for this parameter. */
|
|
@@ -193,9 +193,9 @@ declare namespace gapi.client {
|
|
|
193
193
|
title?: string;
|
|
194
194
|
/** Estimated number of total search results. May not be accurate. */
|
|
195
195
|
totalResults?: string;
|
|
196
|
-
}
|
|
196
|
+
}[];
|
|
197
197
|
/** Metadata representing the previous page of results, if applicable. */
|
|
198
|
-
previousPage?:
|
|
198
|
+
previousPage?: {
|
|
199
199
|
/** Number of search results returned in this set. */
|
|
200
200
|
count?: number;
|
|
201
201
|
/** Restricts search results to documents originating in a particular country. You may use [Boolean operators](https://developers.google.com/custom-search/docs/json_api_reference#BooleanOrSearch) in the `cr` parameter's value. Google WebSearch determines the country of a document by analyzing the following: * The top-level domain (TLD) of the document's URL. * The geographic location of the web server's IP address. See [Country (cr) Parameter Values](https://developers.google.com/custom-search/docs/json_api_reference#countryCollections) for a list of valid values for this parameter. */
|
|
@@ -268,9 +268,9 @@ declare namespace gapi.client {
|
|
|
268
268
|
title?: string;
|
|
269
269
|
/** Estimated number of total search results. May not be accurate. */
|
|
270
270
|
totalResults?: string;
|
|
271
|
-
}
|
|
271
|
+
}[];
|
|
272
272
|
/** Metadata representing the current request. */
|
|
273
|
-
request?:
|
|
273
|
+
request?: {
|
|
274
274
|
/** Number of search results returned in this set. */
|
|
275
275
|
count?: number;
|
|
276
276
|
/** Restricts search results to documents originating in a particular country. You may use [Boolean operators](https://developers.google.com/custom-search/docs/json_api_reference#BooleanOrSearch) in the `cr` parameter's value. Google WebSearch determines the country of a document by analyzing the following: * The top-level domain (TLD) of the document's URL. * The geographic location of the web server's IP address. See [Country (cr) Parameter Values](https://developers.google.com/custom-search/docs/json_api_reference#countryCollections) for a list of valid values for this parameter. */
|
|
@@ -343,7 +343,7 @@ declare namespace gapi.client {
|
|
|
343
343
|
title?: string;
|
|
344
344
|
/** Estimated number of total search results. May not be accurate. */
|
|
345
345
|
totalResults?: string;
|
|
346
|
-
}
|
|
346
|
+
}[];
|
|
347
347
|
};
|
|
348
348
|
/** Metadata about a search operation. */
|
|
349
349
|
searchInformation?: {
|
package/package.json
CHANGED
package/readme.md
CHANGED
|
@@ -11,6 +11,23 @@ Install typings for Custom Search API:
|
|
|
11
11
|
npm install @types/gapi.client.customsearch-v1 --save-dev
|
|
12
12
|
```
|
|
13
13
|
|
|
14
|
+
## TypeScript 6.0+
|
|
15
|
+
|
|
16
|
+
TypeScript 6.0 changed `types` to default to `[]`. You must now explicitly list type packages in `tsconfig.json`:
|
|
17
|
+
|
|
18
|
+
```json
|
|
19
|
+
{
|
|
20
|
+
"compilerOptions": {
|
|
21
|
+
"types": [
|
|
22
|
+
"gapi",
|
|
23
|
+
"gapi.auth2",
|
|
24
|
+
"gapi.client",
|
|
25
|
+
"gapi.client.customsearch-v1"
|
|
26
|
+
]
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
```
|
|
30
|
+
|
|
14
31
|
## Usage
|
|
15
32
|
|
|
16
33
|
You need to initialize Google API client in your code:
|