@seamapi/types 1.1168.0 → 1.1169.0

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.
@@ -56193,6 +56193,7 @@ const openapi = {
56193
56193
  usage: {
56194
56194
  nullable: true,
56195
56195
  properties: {
56196
+ as_of: { format: 'date-time', type: 'string' },
56196
56197
  breakdown: {
56197
56198
  items: {
56198
56199
  properties: {
@@ -56263,6 +56264,7 @@ const openapi = {
56263
56264
  used_tokens: { format: 'float', type: 'number' },
56264
56265
  },
56265
56266
  required: [
56267
+ 'as_of',
56266
56268
  'period_started_at',
56267
56269
  'period_ends_at',
56268
56270
  'package_tokens',
@@ -56762,6 +56764,230 @@ const openapi = {
56762
56764
  'x-undocumented': 'Internal endpoint for Console',
56763
56765
  },
56764
56766
  },
56767
+ '/seam/console/v1/credits/usage/get': {
56768
+ post: {
56769
+ description: "Returns the organization's credit usage for the current subscription period (or the trailing 30 days without a subscription), broken down by workspace, by action and by day.",
56770
+ operationId: 'seamConsoleV1CreditsUsageGetPost',
56771
+ requestBody: {
56772
+ content: {
56773
+ 'application/json': {
56774
+ schema: {
56775
+ properties: {
56776
+ organization_id: { format: 'uuid', type: 'string' },
56777
+ },
56778
+ required: ['organization_id'],
56779
+ type: 'object',
56780
+ },
56781
+ },
56782
+ },
56783
+ },
56784
+ responses: {
56785
+ '200': {
56786
+ content: {
56787
+ 'application/json': {
56788
+ schema: {
56789
+ properties: {
56790
+ ok: { type: 'boolean' },
56791
+ usage: {
56792
+ properties: {
56793
+ as_of: { format: 'date-time', type: 'string' },
56794
+ by_category: {
56795
+ items: {
56796
+ properties: {
56797
+ credits: { format: 'float', type: 'number' },
56798
+ credits_per_unit: {
56799
+ format: 'float',
56800
+ type: 'number',
56801
+ },
56802
+ key: { type: 'string' },
56803
+ kind: {
56804
+ enum: ['connectivity', 'action'],
56805
+ type: 'string',
56806
+ },
56807
+ label: { type: 'string' },
56808
+ percent_of_total: {
56809
+ format: 'float',
56810
+ type: 'number',
56811
+ },
56812
+ quantity: { format: 'float', type: 'number' },
56813
+ },
56814
+ required: [
56815
+ 'kind',
56816
+ 'key',
56817
+ 'label',
56818
+ 'quantity',
56819
+ 'credits_per_unit',
56820
+ 'credits',
56821
+ 'percent_of_total',
56822
+ ],
56823
+ type: 'object',
56824
+ },
56825
+ nullable: true,
56826
+ type: 'array',
56827
+ },
56828
+ by_workspace: {
56829
+ items: {
56830
+ properties: {
56831
+ actions: {
56832
+ items: {
56833
+ properties: {
56834
+ billable_action: { type: 'string' },
56835
+ count: { format: 'float', type: 'number' },
56836
+ credits: {
56837
+ format: 'float',
56838
+ type: 'number',
56839
+ },
56840
+ label: { type: 'string' },
56841
+ },
56842
+ required: [
56843
+ 'billable_action',
56844
+ 'label',
56845
+ 'count',
56846
+ 'credits',
56847
+ ],
56848
+ type: 'object',
56849
+ },
56850
+ type: 'array',
56851
+ },
56852
+ connectivity: {
56853
+ items: {
56854
+ properties: {
56855
+ credits: {
56856
+ format: 'float',
56857
+ type: 'number',
56858
+ },
56859
+ credits_per_device_month: {
56860
+ format: 'float',
56861
+ type: 'number',
56862
+ },
56863
+ device_months: {
56864
+ format: 'float',
56865
+ type: 'number',
56866
+ },
56867
+ label: { type: 'string' },
56868
+ metric: { type: 'string' },
56869
+ },
56870
+ required: [
56871
+ 'metric',
56872
+ 'label',
56873
+ 'device_months',
56874
+ 'credits_per_device_month',
56875
+ 'credits',
56876
+ ],
56877
+ type: 'object',
56878
+ },
56879
+ type: 'array',
56880
+ },
56881
+ credits: { format: 'float', type: 'number' },
56882
+ percent_of_total: {
56883
+ format: 'float',
56884
+ type: 'number',
56885
+ },
56886
+ workspace_id: { nullable: true, type: 'string' },
56887
+ workspace_name: {
56888
+ nullable: true,
56889
+ type: 'string',
56890
+ },
56891
+ },
56892
+ required: [
56893
+ 'workspace_id',
56894
+ 'workspace_name',
56895
+ 'connectivity',
56896
+ 'actions',
56897
+ 'credits',
56898
+ 'percent_of_total',
56899
+ ],
56900
+ type: 'object',
56901
+ },
56902
+ nullable: true,
56903
+ type: 'array',
56904
+ },
56905
+ daily: {
56906
+ items: {
56907
+ properties: {
56908
+ action_credits: {
56909
+ format: 'float',
56910
+ type: 'number',
56911
+ },
56912
+ connectivity_credits: {
56913
+ format: 'float',
56914
+ type: 'number',
56915
+ },
56916
+ date: { type: 'string' },
56917
+ previous_period_credits: {
56918
+ format: 'float',
56919
+ nullable: true,
56920
+ type: 'number',
56921
+ },
56922
+ },
56923
+ required: [
56924
+ 'date',
56925
+ 'connectivity_credits',
56926
+ 'action_credits',
56927
+ 'previous_period_credits',
56928
+ ],
56929
+ type: 'object',
56930
+ },
56931
+ nullable: true,
56932
+ type: 'array',
56933
+ },
56934
+ is_daily_connectivity_included: { type: 'boolean' },
56935
+ package_credits: {
56936
+ format: 'float',
56937
+ nullable: true,
56938
+ type: 'number',
56939
+ },
56940
+ period_ends_at: { format: 'date-time', type: 'string' },
56941
+ period_started_at: {
56942
+ format: 'date-time',
56943
+ type: 'string',
56944
+ },
56945
+ source: {
56946
+ enum: ['metronome', 'estimate'],
56947
+ type: 'string',
56948
+ },
56949
+ used_credits: {
56950
+ format: 'float',
56951
+ nullable: true,
56952
+ type: 'number',
56953
+ },
56954
+ },
56955
+ required: [
56956
+ 'source',
56957
+ 'as_of',
56958
+ 'period_started_at',
56959
+ 'period_ends_at',
56960
+ 'package_credits',
56961
+ 'used_credits',
56962
+ 'by_workspace',
56963
+ 'by_category',
56964
+ 'daily',
56965
+ 'is_daily_connectivity_included',
56966
+ ],
56967
+ type: 'object',
56968
+ },
56969
+ },
56970
+ required: ['usage', 'ok'],
56971
+ type: 'object',
56972
+ },
56973
+ },
56974
+ },
56975
+ description: 'OK',
56976
+ },
56977
+ '400': { description: 'Bad Request' },
56978
+ '401': { description: 'Unauthorized' },
56979
+ },
56980
+ security: [{ console_session_without_workspace: [] }],
56981
+ summary: '/seam/console/v1/credits/usage/get',
56982
+ tags: [],
56983
+ 'x-fern-sdk-group-name': ['seam', 'console', 'v1', 'credits', 'usage'],
56984
+ 'x-fern-sdk-method-name': 'get',
56985
+ 'x-fern-sdk-return-value': 'usage',
56986
+ 'x-response-key': 'usage',
56987
+ 'x-title': "Get an Organization's Credit Usage in Detail",
56988
+ 'x-undocumented': 'Internal endpoint for Console',
56989
+ },
56990
+ },
56765
56991
  '/seam/console/v1/get_resource_locator': {
56766
56992
  get: {
56767
56993
  description: 'Returns the type and system information of a resource given its UUID.',