@openmeter/client 1.0.0-beta-0718635233e9 → 1.0.0-beta-19b4fd5a13eb

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.
@@ -20,6 +20,7 @@ export function listCurrencies(client, req = {}, options) {
20
20
  page: req.page,
21
21
  sort: encodeSort(req.sort, toSnakeCase),
22
22
  filter: req.filter,
23
+ expand: req.expand,
23
24
  }, schemas.listCurrenciesQueryParams);
24
25
  if (client._options.validate) {
25
26
  assertValid(schemas.listCurrenciesQueryParamsWire, query);
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "1.0.0-beta-0718635233e9";
1
+ export declare const SDK_VERSION = "1.0.0-beta-19b4fd5a13eb";
@@ -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-0718635233e9';
5
+ export const SDK_VERSION = '1.0.0-beta-19b4fd5a13eb';
@@ -22,6 +22,12 @@ export interface ListCurrenciesQuery {
22
22
  * To filter currencies by type add the following query param: filter[type]=custom
23
23
  */
24
24
  filter?: ListCurrenciesParamsFilter;
25
+ /**
26
+ * Expand the currencies returned in the response.
27
+ *
28
+ * To include the currently-active cost basis add: expand=cost_basis
29
+ */
30
+ expand?: 'cost_basis'[];
25
31
  }
26
32
  export type ListCurrenciesRequest = AcceptDateStrings<ListCurrenciesQuery>;
27
33
  export type ListCurrenciesResponse = CurrencyPagePaginatedResponse;
@@ -379,6 +379,9 @@ export declare const currencyType: z.ZodEnum<{
379
379
  custom: "custom";
380
380
  fiat: "fiat";
381
381
  }>;
382
+ export declare const currencyExpand: z.ZodEnum<{
383
+ cost_basis: "cost_basis";
384
+ }>;
382
385
  export declare const currencyCodeCustom: z.ZodString;
383
386
  export declare const featureLlmTokenType: z.ZodEnum<{
384
387
  cache_read: "cache_read";
@@ -17380,6 +17383,9 @@ export declare const listCurrenciesQueryParams: z.ZodObject<{
17380
17383
  exists: z.ZodOptional<z.ZodBoolean>;
17381
17384
  }, z.core.$strip>]>>;
17382
17385
  }, z.core.$strip>>;
17386
+ expand: z.ZodOptional<z.ZodArray<z.ZodEnum<{
17387
+ cost_basis: "cost_basis";
17388
+ }>>>;
17383
17389
  }, z.core.$strip>;
17384
17390
  export declare const listCurrenciesResponse: z.ZodObject<{
17385
17391
  data: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -20924,6 +20930,9 @@ export declare const currencyTypeWire: z.ZodEnum<{
20924
20930
  custom: "custom";
20925
20931
  fiat: "fiat";
20926
20932
  }>;
20933
+ export declare const currencyExpandWire: z.ZodEnum<{
20934
+ cost_basis: "cost_basis";
20935
+ }>;
20927
20936
  export declare const currencyCodeCustomWire: z.ZodString;
20928
20937
  export declare const featureLlmTokenTypeWire: z.ZodEnum<{
20929
20938
  cache_read: "cache_read";
@@ -37901,6 +37910,9 @@ export declare const listCurrenciesQueryParamsWire: z.ZodObject<{
37901
37910
  exists: z.ZodOptional<z.ZodBoolean>;
37902
37911
  }, z.core.$strict>]>>;
37903
37912
  }, z.core.$strict>>;
37913
+ expand: z.ZodOptional<z.ZodArray<z.ZodEnum<{
37914
+ cost_basis: "cost_basis";
37915
+ }>>>;
37904
37916
  }, z.core.$strip>;
37905
37917
  export declare const listCurrenciesResponseWire: z.ZodObject<{
37906
37918
  data: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -686,6 +686,9 @@ export const updatePriceFree = z
686
686
  export const currencyType = z
687
687
  .enum(['fiat', 'custom'])
688
688
  .describe('Currency type for custom currencies. It should be a unique code but not conflicting with any existing standard currency codes.');
689
+ export const currencyExpand = z
690
+ .enum(['cost_basis'])
691
+ .describe("Expands for currencies. Values: - `cost_basis`: The currency's currently-active cost basis.");
689
692
  export const currencyCodeCustom = z
690
693
  .string()
691
694
  .min(4)
@@ -4869,6 +4872,10 @@ export const listCurrenciesQueryParams = z.object({
4869
4872
  .describe('Determines which page of the collection to retrieve.'),
4870
4873
  sort: sortQuery.optional(),
4871
4874
  filter: listCurrenciesParamsFilter.optional(),
4875
+ expand: z
4876
+ .array(currencyExpand)
4877
+ .optional()
4878
+ .describe('Expand the currencies returned in the response. To include the currently-active cost basis add: expand=cost_basis'),
4872
4879
  });
4873
4880
  export const listCurrenciesResponse = z.object({
4874
4881
  data: z.array(currency),
@@ -5799,6 +5806,9 @@ export const updatePriceFreeWire = z
5799
5806
  export const currencyTypeWire = z
5800
5807
  .enum(['fiat', 'custom'])
5801
5808
  .describe('Currency type for custom currencies. It should be a unique code but not conflicting with any existing standard currency codes.');
5809
+ export const currencyExpandWire = z
5810
+ .enum(['cost_basis'])
5811
+ .describe("Expands for currencies. Values: - `cost_basis`: The currency's currently-active cost basis.");
5802
5812
  export const currencyCodeCustomWire = z
5803
5813
  .string()
5804
5814
  .min(4)
@@ -9985,6 +9995,10 @@ export const listCurrenciesQueryParamsWire = z.object({
9985
9995
  .optional()
9986
9996
  .describe('Sort currencies returned in the response. Supported sort attributes are: - `code` (default) - `name` The `asc` suffix is optional as the default sort order is ascending. The `desc` suffix is used to specify a descending order.'),
9987
9997
  filter: listCurrenciesParamsFilterWire.optional(),
9998
+ expand: z
9999
+ .array(currencyExpandWire)
10000
+ .optional()
10001
+ .describe('Expand the currencies returned in the response. To include the currently-active cost basis add: expand=cost_basis'),
9988
10002
  });
9989
10003
  export const listCurrenciesResponseWire = z.strictObject({
9990
10004
  data: z.array(currencyWire),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openmeter/client",
3
- "version": "1.0.0-beta-0718635233e9",
3
+ "version": "1.0.0-beta-19b4fd5a13eb",
4
4
  "description": "Official TypeScript SDK for the OpenMeter API — usage metering and billing",
5
5
  "keywords": [
6
6
  "openmeter",