@openmeter/client 1.0.0-beta-5e0d2a9dd8de → 1.0.0-beta-65104fd1fe60
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/dist/funcs/customers.js
CHANGED
|
@@ -931,8 +931,12 @@ export function listCreditGrants(client, req, options) {
|
|
|
931
931
|
}
|
|
932
932
|
return encodeURIComponent(String(pathParams.customerId));
|
|
933
933
|
})()}/credits/grants`;
|
|
934
|
+
if (client._options.validate && req.sort !== undefined) {
|
|
935
|
+
assertValid(schemas.listCreditGrantsQueryParams.shape.sort, req.sort);
|
|
936
|
+
}
|
|
934
937
|
const query = toWire({
|
|
935
938
|
page: req.page,
|
|
939
|
+
sort: encodeSort(req.sort, toSnakeCase),
|
|
936
940
|
filter: req.filter,
|
|
937
941
|
}, schemas.listCreditGrantsQueryParams);
|
|
938
942
|
if (client._options.validate) {
|
package/dist/lib/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "1.0.0-beta-
|
|
1
|
+
export declare const SDK_VERSION = "1.0.0-beta-65104fd1fe60";
|
package/dist/lib/version.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
// The committed value is a dev placeholder. The publish flow
|
|
3
3
|
// (`make -C api/spec publish-aip-sdk`) stamps the real release version here
|
|
4
4
|
// before `pnpm publish`, after `pnpm version` updates package.json.
|
|
5
|
-
export const SDK_VERSION = '1.0.0-beta-
|
|
5
|
+
export const SDK_VERSION = '1.0.0-beta-65104fd1fe60';
|
|
@@ -194,6 +194,12 @@ export interface ListCreditGrantsQuery {
|
|
|
194
194
|
size?: number;
|
|
195
195
|
number?: number;
|
|
196
196
|
};
|
|
197
|
+
/**
|
|
198
|
+
* Sort credit grants by `created_at`, `updated_at`, `name`, or `id`. Defaults to
|
|
199
|
+
* `created_at desc`. The `asc` suffix is optional when a sort attribute is
|
|
200
|
+
* supplied. Supports one attribute; ties are broken by `id` in the same direction.
|
|
201
|
+
*/
|
|
202
|
+
sort?: SortQueryInput;
|
|
197
203
|
/** Filter credit grants returned in the response. */
|
|
198
204
|
filter?: ListCreditGrantsParamsFilter;
|
|
199
205
|
}
|
package/dist/models/schemas.d.ts
CHANGED
|
@@ -21122,6 +21122,10 @@ export declare const listCreditGrantsQueryParams: z.ZodObject<{
|
|
|
21122
21122
|
size: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
21123
21123
|
number: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
21124
21124
|
}, z.core.$strip>>;
|
|
21125
|
+
sort: z.ZodOptional<z.ZodObject<{
|
|
21126
|
+
by: z.ZodString;
|
|
21127
|
+
order: z.ZodDefault<z.ZodOptional<z.ZodUnion<readonly [z.ZodLiteral<"asc">, z.ZodLiteral<"desc">]>>>;
|
|
21128
|
+
}, z.core.$strip>>;
|
|
21125
21129
|
filter: z.ZodOptional<z.ZodObject<{
|
|
21126
21130
|
status: z.ZodOptional<z.ZodEnum<{
|
|
21127
21131
|
active: "active";
|
|
@@ -58230,6 +58234,7 @@ export declare const listCreditGrantsQueryParamsWire: z.ZodObject<{
|
|
|
58230
58234
|
size: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
58231
58235
|
number: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
58232
58236
|
}, z.core.$strict>>;
|
|
58237
|
+
sort: z.ZodOptional<z.ZodString>;
|
|
58233
58238
|
filter: z.ZodOptional<z.ZodObject<{
|
|
58234
58239
|
status: z.ZodOptional<z.ZodEnum<{
|
|
58235
58240
|
active: "active";
|
package/dist/models/schemas.js
CHANGED
|
@@ -6544,6 +6544,7 @@ export const listCreditGrantsQueryParams = z.object({
|
|
|
6544
6544
|
})
|
|
6545
6545
|
.optional()
|
|
6546
6546
|
.describe('Determines which page of the collection to retrieve.'),
|
|
6547
|
+
sort: sortQuery.optional(),
|
|
6547
6548
|
filter: listCreditGrantsParamsFilter.optional(),
|
|
6548
6549
|
});
|
|
6549
6550
|
export const listCreditGrantsResponse = z.object({
|
|
@@ -13793,6 +13794,10 @@ export const listCreditGrantsQueryParamsWire = z.object({
|
|
|
13793
13794
|
})
|
|
13794
13795
|
.optional()
|
|
13795
13796
|
.describe('Determines which page of the collection to retrieve.'),
|
|
13797
|
+
sort: z
|
|
13798
|
+
.string()
|
|
13799
|
+
.optional()
|
|
13800
|
+
.describe('Sort credit grants by `created_at`, `updated_at`, `name`, or `id`. Defaults to `created_at desc`. The `asc` suffix is optional when a sort attribute is supplied. Supports one attribute; ties are broken by `id` in the same direction.'),
|
|
13796
13801
|
filter: listCreditGrantsParamsFilterWire.optional(),
|
|
13797
13802
|
});
|
|
13798
13803
|
export const listCreditGrantsResponseWire = z.strictObject({
|