Skip to content

Commit aea7e10

Browse files
release: 1.1.0 (#53)
* chore(docs): grammar improvements * codegen metadata * feat(api): add beta label endpoints * release: 1.1.0 --------- Co-authored-by: stainless-app[bot] <142633134+stainless-app[bot]@users.noreply.github.com>
1 parent c44e88a commit aea7e10

11 files changed

Lines changed: 266 additions & 9 deletions

File tree

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "1.0.1"
2+
".": "1.1.0"
33
}

.stats.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
configured_endpoints: 7
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/grid%2Fspreadsheet-api-8f089189d87fe061afe62a54cdce6752e1b9597de7fdaa4154412ce2115c7ed4.yml
3-
openapi_spec_hash: 2bff1feefeadafaa3c714059c1ebf682
4-
config_hash: 8d14e76153d6c3003008e70a59928aa8
1+
configured_endpoints: 9
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/grid%2Fspreadsheet-api-c04aecbf881fa8800053188fa5d587605aa4238cf9d732ebd6c18d7b8c65e400.yml
3+
openapi_spec_hash: ce7f54c0cb3e2baccca845c7e83d44fe
4+
config_hash: 30cb36a4b395dedfacaa0aad4fcc34c6

CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,18 @@
11
# Changelog
22

3+
## 1.1.0 (2025-05-23)
4+
5+
Full Changelog: [v1.0.1...v1.1.0](https://github.com/GRID-is/api-sdk-ts/compare/v1.0.1...v1.1.0)
6+
7+
### Features
8+
9+
* **api:** add beta label endpoints ([de15d07](https://github.com/GRID-is/api-sdk-ts/commit/de15d07e2079185d55cfeed7edff950b84450de7))
10+
11+
12+
### Chores
13+
14+
* **docs:** grammar improvements ([86247ff](https://github.com/GRID-is/api-sdk-ts/commit/86247ff810cbd3cf395be6453d6c648a9ba7b861))
15+
316
## 1.0.1 (2025-05-15)
417

518
Full Changelog: [v1.0.0...v1.0.1](https://github.com/GRID-is/api-sdk-ts/compare/v1.0.0...v1.0.1)

SECURITY.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@ before making any information public.
1616
## Reporting Non-SDK Related Security Issues
1717

1818
If you encounter security issues that are not directly related to SDKs but pertain to the services
19-
or products provided by Grid please follow the respective company's security reporting guidelines.
19+
or products provided by Grid, please follow the respective company's security reporting guidelines.
2020

2121
### Grid Terms and Policies
2222

23-
Please contact info@grid.is for any questions or concerns regarding security of our services.
23+
Please contact info@grid.is for any questions or concerns regarding the security of our services.
2424

2525
---
2626

api.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,15 @@ Methods:
1717
- <code title="post /v1/workbooks/{id}/chart">client.workbooks.<a href="./src/resources/workbooks.ts">renderChart</a>(id, { ...params }) -> Response</code>
1818
- <code title="post /v1/workbooks">client.workbooks.<a href="./src/resources/workbooks.ts">upload</a>({ ...params }) -> WorkbookUploadResponse</code>
1919
- <code title="post /v1/workbooks/{id}/values">client.workbooks.<a href="./src/resources/workbooks.ts">values</a>(id, { ...params }) -> WorkbookValuesResponse</code>
20+
21+
# Beta
22+
23+
Types:
24+
25+
- <code><a href="./src/resources/beta.ts">BetaGetWorkbookLabelsResponse</a></code>
26+
- <code><a href="./src/resources/beta.ts">BetaSearchLabelsResponse</a></code>
27+
28+
Methods:
29+
30+
- <code title="get /v1/workbooks/{id}/labels">client.beta.<a href="./src/resources/beta.ts">getWorkbookLabels</a>(id) -> BetaGetWorkbookLabelsResponse</code>
31+
- <code title="post /v1/workbooks/search/labels">client.beta.<a href="./src/resources/beta.ts">searchLabels</a>({ ...params }) -> BetaSearchLabelsResponse</code>

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@grid-is/api",
3-
"version": "1.0.1",
3+
"version": "1.1.0",
44
"description": "The official TypeScript library for the Grid API",
55
"author": "Grid <info@grid.is>",
66
"types": "dist/index.d.ts",

src/client.ts

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,12 @@ import { APIPromise } from './core/api-promise';
2222
import { type Fetch } from './internal/builtin-types';
2323
import { HeadersLike, NullableHeaders, buildHeaders } from './internal/headers';
2424
import { FinalRequestOptions, RequestOptions } from './internal/request-options';
25+
import {
26+
Beta,
27+
BetaGetWorkbookLabelsResponse,
28+
BetaSearchLabelsParams,
29+
BetaSearchLabelsResponse,
30+
} from './resources/beta';
2531
import {
2632
WorkbookCalcParams,
2733
WorkbookCalcResponse,
@@ -729,8 +735,10 @@ export class Grid {
729735
static toFile = Uploads.toFile;
730736

731737
workbooks: API.Workbooks = new API.Workbooks(this);
738+
beta: API.Beta = new API.Beta(this);
732739
}
733740
Grid.Workbooks = Workbooks;
741+
Grid.Beta = Beta;
734742
export declare namespace Grid {
735743
export type RequestOptions = Opts.RequestOptions;
736744

@@ -756,4 +764,11 @@ export declare namespace Grid {
756764
type WorkbookUploadParams as WorkbookUploadParams,
757765
type WorkbookValuesParams as WorkbookValuesParams,
758766
};
767+
768+
export {
769+
Beta as Beta,
770+
type BetaGetWorkbookLabelsResponse as BetaGetWorkbookLabelsResponse,
771+
type BetaSearchLabelsResponse as BetaSearchLabelsResponse,
772+
type BetaSearchLabelsParams as BetaSearchLabelsParams,
773+
};
759774
}

src/resources/beta.ts

Lines changed: 172 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,172 @@
1+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
import { APIResource } from '../core/resource';
4+
import { APIPromise } from '../core/api-promise';
5+
import { RequestOptions } from '../internal/request-options';
6+
import { path } from '../internal/utils/path';
7+
8+
export class Beta extends APIResource {
9+
/**
10+
* Retrieve labels automatically detected for cells and ranges in the workbook.
11+
*/
12+
getWorkbookLabels(id: string, options?: RequestOptions): APIPromise<BetaGetWorkbookLabelsResponse> {
13+
return this._client.get(path`/v1/workbooks/${id}/labels`, options);
14+
}
15+
16+
/**
17+
* Search data labels across all spreadsheets uploaded to an account
18+
*/
19+
searchLabels(body: BetaSearchLabelsParams, options?: RequestOptions): APIPromise<BetaSearchLabelsResponse> {
20+
return this._client.post('/v1/workbooks/search/labels', { body, ...options });
21+
}
22+
}
23+
24+
export interface BetaGetWorkbookLabelsResponse {
25+
/**
26+
* The date/time the labels were detected and stored
27+
*/
28+
created: string;
29+
30+
/**
31+
* The labels associated with the workbook
32+
*/
33+
labels: Array<BetaGetWorkbookLabelsResponse.Label>;
34+
35+
/**
36+
* The id of the workbook the labels belong to
37+
*/
38+
workbook_id: string;
39+
40+
/**
41+
* The version of the workbook the labels belong to
42+
*/
43+
workbook_version: number;
44+
}
45+
46+
export namespace BetaGetWorkbookLabelsResponse {
47+
export interface Label {
48+
/**
49+
* The cell address/reference which the label applies to
50+
*/
51+
at: string;
52+
53+
/**
54+
* The cell address/reference which the label applies to
55+
*/
56+
for: string;
57+
58+
/**
59+
* The label string
60+
*/
61+
text: string;
62+
63+
/**
64+
* The type of the label, almost always text, not to be confused with cell type
65+
*/
66+
type?: string | null;
67+
}
68+
}
69+
70+
/**
71+
* The results of a spreadsheet data label search.
72+
*/
73+
export interface BetaSearchLabelsResponse {
74+
results: Array<BetaSearchLabelsResponse.Result>;
75+
}
76+
77+
export namespace BetaSearchLabelsResponse {
78+
/**
79+
* Contains a workbook that includes data labels that match the search query.
80+
*/
81+
export interface Result {
82+
/**
83+
* UUID for the user that uploaded the workbook. This will always be the UUID of
84+
* the account linked to the API key used in the request.
85+
*/
86+
creator_id: string;
87+
88+
/**
89+
* Generated description summarising the contents of the workbook
90+
*/
91+
description: string;
92+
93+
/**
94+
* Original filename of the workbook
95+
*/
96+
filename: string;
97+
98+
/**
99+
* Most recent version number of the workbook
100+
*/
101+
latest_version: number;
102+
103+
/**
104+
* Absolute URL for a thumbnail of the workbook's first sheet
105+
*/
106+
thumbnail_url: string;
107+
108+
/**
109+
* UUID for the workbook
110+
*/
111+
workbook_id: string;
112+
113+
labels?: Array<Result.Label>;
114+
115+
/**
116+
* Relevance ranking of the workbook in relation to the search results (higher is
117+
* better)
118+
*/
119+
score?: number | null;
120+
}
121+
122+
export namespace Result {
123+
/**
124+
* A label search result. Includes the location, text content, value, and score.
125+
*/
126+
export interface Label {
127+
/**
128+
* Cell reference or range that contains the labelled data
129+
*/
130+
for: string;
131+
132+
/**
133+
* Text content of the label
134+
*/
135+
text: string;
136+
137+
/**
138+
* The labelled data value(s). If a range of data is labelled, this will be a
139+
* stringified JSON array
140+
*/
141+
value: string;
142+
143+
/**
144+
* Relevance ranking of the workbook in relation to the search results (higher is
145+
* better)
146+
*/
147+
score?: number | null;
148+
}
149+
}
150+
}
151+
152+
export interface BetaSearchLabelsParams {
153+
query: string;
154+
155+
/**
156+
* Maximum number of labels to return per workbook
157+
*/
158+
max_labels?: number | null;
159+
160+
/**
161+
* Maximum number of workbooks to return results for
162+
*/
163+
max_results?: number | null;
164+
}
165+
166+
export declare namespace Beta {
167+
export {
168+
type BetaGetWorkbookLabelsResponse as BetaGetWorkbookLabelsResponse,
169+
type BetaSearchLabelsResponse as BetaSearchLabelsResponse,
170+
type BetaSearchLabelsParams as BetaSearchLabelsParams,
171+
};
172+
}

src/resources/index.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

3+
export {
4+
Beta,
5+
type BetaGetWorkbookLabelsResponse,
6+
type BetaSearchLabelsResponse,
7+
type BetaSearchLabelsParams,
8+
} from './beta';
39
export {
410
Workbooks,
511
type WorkbookListResponse,

src/version.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export const VERSION = '1.0.1'; // x-release-please-version
1+
export const VERSION = '1.1.0'; // x-release-please-version

0 commit comments

Comments
 (0)