@seamapi/types 1.1168.0 → 1.1170.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.
@@ -56174,7 +56174,40 @@ const openapi = {
56174
56174
  nullable: true,
56175
56175
  type: 'string',
56176
56176
  },
56177
+ pending_upgrade: {
56178
+ nullable: true,
56179
+ properties: {
56180
+ hosted_invoice_url: {
56181
+ nullable: true,
56182
+ type: 'string',
56183
+ },
56184
+ package_quantity: {
56185
+ format: 'float',
56186
+ type: 'number',
56187
+ },
56188
+ },
56189
+ required: [
56190
+ 'package_quantity',
56191
+ 'hosted_invoice_url',
56192
+ ],
56193
+ type: 'object',
56194
+ },
56177
56195
  price_cents: { format: 'float', type: 'number' },
56196
+ scheduled_change_at: {
56197
+ format: 'date-time',
56198
+ nullable: true,
56199
+ type: 'string',
56200
+ },
56201
+ scheduled_package_quantity: {
56202
+ format: 'float',
56203
+ nullable: true,
56204
+ type: 'number',
56205
+ },
56206
+ scheduled_price_cents: {
56207
+ format: 'float',
56208
+ nullable: true,
56209
+ type: 'number',
56210
+ },
56178
56211
  status: { type: 'string' },
56179
56212
  },
56180
56213
  required: [
@@ -56186,6 +56219,10 @@ const openapi = {
56186
56219
  'current_period_ends_at',
56187
56220
  'past_due_since',
56188
56221
  'canceled_at',
56222
+ 'scheduled_package_quantity',
56223
+ 'scheduled_price_cents',
56224
+ 'scheduled_change_at',
56225
+ 'pending_upgrade',
56189
56226
  ],
56190
56227
  type: 'object',
56191
56228
  },
@@ -56193,6 +56230,7 @@ const openapi = {
56193
56230
  usage: {
56194
56231
  nullable: true,
56195
56232
  properties: {
56233
+ as_of: { format: 'date-time', type: 'string' },
56196
56234
  breakdown: {
56197
56235
  items: {
56198
56236
  properties: {
@@ -56263,6 +56301,7 @@ const openapi = {
56263
56301
  used_tokens: { format: 'float', type: 'number' },
56264
56302
  },
56265
56303
  required: [
56304
+ 'as_of',
56266
56305
  'period_started_at',
56267
56306
  'period_ends_at',
56268
56307
  'package_tokens',
@@ -56626,7 +56665,37 @@ const openapi = {
56626
56665
  nullable: true,
56627
56666
  type: 'string',
56628
56667
  },
56668
+ pending_upgrade: {
56669
+ nullable: true,
56670
+ properties: {
56671
+ hosted_invoice_url: {
56672
+ nullable: true,
56673
+ type: 'string',
56674
+ },
56675
+ package_quantity: {
56676
+ format: 'float',
56677
+ type: 'number',
56678
+ },
56679
+ },
56680
+ required: ['package_quantity', 'hosted_invoice_url'],
56681
+ type: 'object',
56682
+ },
56629
56683
  price_cents: { format: 'float', type: 'number' },
56684
+ scheduled_change_at: {
56685
+ format: 'date-time',
56686
+ nullable: true,
56687
+ type: 'string',
56688
+ },
56689
+ scheduled_package_quantity: {
56690
+ format: 'float',
56691
+ nullable: true,
56692
+ type: 'number',
56693
+ },
56694
+ scheduled_price_cents: {
56695
+ format: 'float',
56696
+ nullable: true,
56697
+ type: 'number',
56698
+ },
56630
56699
  status: { type: 'string' },
56631
56700
  },
56632
56701
  required: [
@@ -56638,6 +56707,10 @@ const openapi = {
56638
56707
  'current_period_ends_at',
56639
56708
  'past_due_since',
56640
56709
  'canceled_at',
56710
+ 'scheduled_package_quantity',
56711
+ 'scheduled_price_cents',
56712
+ 'scheduled_change_at',
56713
+ 'pending_upgrade',
56641
56714
  ],
56642
56715
  type: 'object',
56643
56716
  },
@@ -56669,6 +56742,296 @@ const openapi = {
56669
56742
  'x-undocumented': 'Internal endpoint for Console',
56670
56743
  },
56671
56744
  },
56745
+ '/seam/console/v1/credits/subscription/change': {
56746
+ post: {
56747
+ description: 'Upgrades to a larger package immediately, charging its full price and carrying the unused credits over, or schedules a downgrade to a smaller package for the end of the current period.',
56748
+ operationId: 'seamConsoleV1CreditsSubscriptionChangePost',
56749
+ requestBody: {
56750
+ content: {
56751
+ 'application/json': {
56752
+ schema: {
56753
+ properties: {
56754
+ organization_id: { format: 'uuid', type: 'string' },
56755
+ package_quantity: {
56756
+ exclusiveMinimum: true,
56757
+ minimum: 0,
56758
+ type: 'integer',
56759
+ },
56760
+ },
56761
+ required: ['organization_id', 'package_quantity'],
56762
+ type: 'object',
56763
+ },
56764
+ },
56765
+ },
56766
+ },
56767
+ responses: {
56768
+ '200': {
56769
+ content: {
56770
+ 'application/json': {
56771
+ schema: {
56772
+ properties: {
56773
+ change: {
56774
+ properties: {
56775
+ carried_credits: {
56776
+ format: 'float',
56777
+ nullable: true,
56778
+ type: 'number',
56779
+ },
56780
+ hosted_invoice_url: { nullable: true, type: 'string' },
56781
+ kind: {
56782
+ enum: ['upgrade', 'downgrade'],
56783
+ type: 'string',
56784
+ },
56785
+ status: {
56786
+ enum: [
56787
+ 'applied',
56788
+ 'scheduled',
56789
+ 'awaiting_authentication',
56790
+ 'processing',
56791
+ ],
56792
+ type: 'string',
56793
+ },
56794
+ },
56795
+ required: [
56796
+ 'kind',
56797
+ 'status',
56798
+ 'hosted_invoice_url',
56799
+ 'carried_credits',
56800
+ ],
56801
+ type: 'object',
56802
+ },
56803
+ credit_subscription: {
56804
+ properties: {
56805
+ canceled_at: {
56806
+ format: 'date-time',
56807
+ nullable: true,
56808
+ type: 'string',
56809
+ },
56810
+ credit_subscription_id: {
56811
+ format: 'uuid',
56812
+ type: 'string',
56813
+ },
56814
+ current_period_ends_at: {
56815
+ format: 'date-time',
56816
+ nullable: true,
56817
+ type: 'string',
56818
+ },
56819
+ current_period_started_at: {
56820
+ format: 'date-time',
56821
+ nullable: true,
56822
+ type: 'string',
56823
+ },
56824
+ package_quantity: { format: 'float', type: 'number' },
56825
+ past_due_since: {
56826
+ format: 'date-time',
56827
+ nullable: true,
56828
+ type: 'string',
56829
+ },
56830
+ pending_upgrade: {
56831
+ nullable: true,
56832
+ properties: {
56833
+ hosted_invoice_url: {
56834
+ nullable: true,
56835
+ type: 'string',
56836
+ },
56837
+ package_quantity: {
56838
+ format: 'float',
56839
+ type: 'number',
56840
+ },
56841
+ },
56842
+ required: ['package_quantity', 'hosted_invoice_url'],
56843
+ type: 'object',
56844
+ },
56845
+ price_cents: { format: 'float', type: 'number' },
56846
+ scheduled_change_at: {
56847
+ format: 'date-time',
56848
+ nullable: true,
56849
+ type: 'string',
56850
+ },
56851
+ scheduled_package_quantity: {
56852
+ format: 'float',
56853
+ nullable: true,
56854
+ type: 'number',
56855
+ },
56856
+ scheduled_price_cents: {
56857
+ format: 'float',
56858
+ nullable: true,
56859
+ type: 'number',
56860
+ },
56861
+ status: { type: 'string' },
56862
+ },
56863
+ required: [
56864
+ 'credit_subscription_id',
56865
+ 'status',
56866
+ 'package_quantity',
56867
+ 'price_cents',
56868
+ 'current_period_started_at',
56869
+ 'current_period_ends_at',
56870
+ 'past_due_since',
56871
+ 'canceled_at',
56872
+ 'scheduled_package_quantity',
56873
+ 'scheduled_price_cents',
56874
+ 'scheduled_change_at',
56875
+ 'pending_upgrade',
56876
+ ],
56877
+ type: 'object',
56878
+ },
56879
+ ok: { type: 'boolean' },
56880
+ },
56881
+ required: ['credit_subscription', 'change', 'ok'],
56882
+ type: 'object',
56883
+ },
56884
+ },
56885
+ },
56886
+ description: 'OK',
56887
+ },
56888
+ '400': { description: 'Bad Request' },
56889
+ '401': { description: 'Unauthorized' },
56890
+ },
56891
+ security: [{ console_session_without_workspace: [] }],
56892
+ summary: '/seam/console/v1/credits/subscription/change',
56893
+ tags: [],
56894
+ 'x-fern-sdk-group-name': [
56895
+ 'seam',
56896
+ 'console',
56897
+ 'v1',
56898
+ 'credits',
56899
+ 'subscription',
56900
+ ],
56901
+ 'x-fern-sdk-method-name': 'change',
56902
+ 'x-response-key': null,
56903
+ 'x-title': "Change a Credit Subscription's Package",
56904
+ 'x-undocumented': 'Internal endpoint for Console',
56905
+ },
56906
+ },
56907
+ '/seam/console/v1/credits/subscription/change/cancel': {
56908
+ post: {
56909
+ description: 'Undoes a package downgrade that has not taken effect yet, so the credit subscription keeps its current package.',
56910
+ operationId: 'seamConsoleV1CreditsSubscriptionChangeCancelPost',
56911
+ requestBody: {
56912
+ content: {
56913
+ 'application/json': {
56914
+ schema: {
56915
+ properties: {
56916
+ organization_id: { format: 'uuid', type: 'string' },
56917
+ },
56918
+ required: ['organization_id'],
56919
+ type: 'object',
56920
+ },
56921
+ },
56922
+ },
56923
+ },
56924
+ responses: {
56925
+ '200': {
56926
+ content: {
56927
+ 'application/json': {
56928
+ schema: {
56929
+ properties: {
56930
+ credit_subscription: {
56931
+ properties: {
56932
+ canceled_at: {
56933
+ format: 'date-time',
56934
+ nullable: true,
56935
+ type: 'string',
56936
+ },
56937
+ credit_subscription_id: {
56938
+ format: 'uuid',
56939
+ type: 'string',
56940
+ },
56941
+ current_period_ends_at: {
56942
+ format: 'date-time',
56943
+ nullable: true,
56944
+ type: 'string',
56945
+ },
56946
+ current_period_started_at: {
56947
+ format: 'date-time',
56948
+ nullable: true,
56949
+ type: 'string',
56950
+ },
56951
+ package_quantity: { format: 'float', type: 'number' },
56952
+ past_due_since: {
56953
+ format: 'date-time',
56954
+ nullable: true,
56955
+ type: 'string',
56956
+ },
56957
+ pending_upgrade: {
56958
+ nullable: true,
56959
+ properties: {
56960
+ hosted_invoice_url: {
56961
+ nullable: true,
56962
+ type: 'string',
56963
+ },
56964
+ package_quantity: {
56965
+ format: 'float',
56966
+ type: 'number',
56967
+ },
56968
+ },
56969
+ required: ['package_quantity', 'hosted_invoice_url'],
56970
+ type: 'object',
56971
+ },
56972
+ price_cents: { format: 'float', type: 'number' },
56973
+ scheduled_change_at: {
56974
+ format: 'date-time',
56975
+ nullable: true,
56976
+ type: 'string',
56977
+ },
56978
+ scheduled_package_quantity: {
56979
+ format: 'float',
56980
+ nullable: true,
56981
+ type: 'number',
56982
+ },
56983
+ scheduled_price_cents: {
56984
+ format: 'float',
56985
+ nullable: true,
56986
+ type: 'number',
56987
+ },
56988
+ status: { type: 'string' },
56989
+ },
56990
+ required: [
56991
+ 'credit_subscription_id',
56992
+ 'status',
56993
+ 'package_quantity',
56994
+ 'price_cents',
56995
+ 'current_period_started_at',
56996
+ 'current_period_ends_at',
56997
+ 'past_due_since',
56998
+ 'canceled_at',
56999
+ 'scheduled_package_quantity',
57000
+ 'scheduled_price_cents',
57001
+ 'scheduled_change_at',
57002
+ 'pending_upgrade',
57003
+ ],
57004
+ type: 'object',
57005
+ },
57006
+ ok: { type: 'boolean' },
57007
+ },
57008
+ required: ['credit_subscription', 'ok'],
57009
+ type: 'object',
57010
+ },
57011
+ },
57012
+ },
57013
+ description: 'OK',
57014
+ },
57015
+ '400': { description: 'Bad Request' },
57016
+ '401': { description: 'Unauthorized' },
57017
+ },
57018
+ security: [{ console_session_without_workspace: [] }],
57019
+ summary: '/seam/console/v1/credits/subscription/change/cancel',
57020
+ tags: [],
57021
+ 'x-fern-sdk-group-name': [
57022
+ 'seam',
57023
+ 'console',
57024
+ 'v1',
57025
+ 'credits',
57026
+ 'subscription',
57027
+ 'change',
57028
+ ],
57029
+ 'x-fern-sdk-method-name': 'cancel',
57030
+ 'x-response-key': null,
57031
+ 'x-title': 'Cancel a Scheduled Credit Package Change',
57032
+ 'x-undocumented': 'Internal endpoint for Console',
57033
+ },
57034
+ },
56672
57035
  '/seam/console/v1/credits/subscription/resume': {
56673
57036
  post: {
56674
57037
  description: 'Undoes a cancellation that has not taken effect yet, so the credit subscription renews at the end of its current period.',
@@ -56719,7 +57082,37 @@ const openapi = {
56719
57082
  nullable: true,
56720
57083
  type: 'string',
56721
57084
  },
57085
+ pending_upgrade: {
57086
+ nullable: true,
57087
+ properties: {
57088
+ hosted_invoice_url: {
57089
+ nullable: true,
57090
+ type: 'string',
57091
+ },
57092
+ package_quantity: {
57093
+ format: 'float',
57094
+ type: 'number',
57095
+ },
57096
+ },
57097
+ required: ['package_quantity', 'hosted_invoice_url'],
57098
+ type: 'object',
57099
+ },
56722
57100
  price_cents: { format: 'float', type: 'number' },
57101
+ scheduled_change_at: {
57102
+ format: 'date-time',
57103
+ nullable: true,
57104
+ type: 'string',
57105
+ },
57106
+ scheduled_package_quantity: {
57107
+ format: 'float',
57108
+ nullable: true,
57109
+ type: 'number',
57110
+ },
57111
+ scheduled_price_cents: {
57112
+ format: 'float',
57113
+ nullable: true,
57114
+ type: 'number',
57115
+ },
56723
57116
  status: { type: 'string' },
56724
57117
  },
56725
57118
  required: [
@@ -56731,6 +57124,10 @@ const openapi = {
56731
57124
  'current_period_ends_at',
56732
57125
  'past_due_since',
56733
57126
  'canceled_at',
57127
+ 'scheduled_package_quantity',
57128
+ 'scheduled_price_cents',
57129
+ 'scheduled_change_at',
57130
+ 'pending_upgrade',
56734
57131
  ],
56735
57132
  type: 'object',
56736
57133
  },
@@ -56762,6 +57159,230 @@ const openapi = {
56762
57159
  'x-undocumented': 'Internal endpoint for Console',
56763
57160
  },
56764
57161
  },
57162
+ '/seam/console/v1/credits/usage/get': {
57163
+ post: {
57164
+ 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.",
57165
+ operationId: 'seamConsoleV1CreditsUsageGetPost',
57166
+ requestBody: {
57167
+ content: {
57168
+ 'application/json': {
57169
+ schema: {
57170
+ properties: {
57171
+ organization_id: { format: 'uuid', type: 'string' },
57172
+ },
57173
+ required: ['organization_id'],
57174
+ type: 'object',
57175
+ },
57176
+ },
57177
+ },
57178
+ },
57179
+ responses: {
57180
+ '200': {
57181
+ content: {
57182
+ 'application/json': {
57183
+ schema: {
57184
+ properties: {
57185
+ ok: { type: 'boolean' },
57186
+ usage: {
57187
+ properties: {
57188
+ as_of: { format: 'date-time', type: 'string' },
57189
+ by_category: {
57190
+ items: {
57191
+ properties: {
57192
+ credits: { format: 'float', type: 'number' },
57193
+ credits_per_unit: {
57194
+ format: 'float',
57195
+ type: 'number',
57196
+ },
57197
+ key: { type: 'string' },
57198
+ kind: {
57199
+ enum: ['connectivity', 'action'],
57200
+ type: 'string',
57201
+ },
57202
+ label: { type: 'string' },
57203
+ percent_of_total: {
57204
+ format: 'float',
57205
+ type: 'number',
57206
+ },
57207
+ quantity: { format: 'float', type: 'number' },
57208
+ },
57209
+ required: [
57210
+ 'kind',
57211
+ 'key',
57212
+ 'label',
57213
+ 'quantity',
57214
+ 'credits_per_unit',
57215
+ 'credits',
57216
+ 'percent_of_total',
57217
+ ],
57218
+ type: 'object',
57219
+ },
57220
+ nullable: true,
57221
+ type: 'array',
57222
+ },
57223
+ by_workspace: {
57224
+ items: {
57225
+ properties: {
57226
+ actions: {
57227
+ items: {
57228
+ properties: {
57229
+ billable_action: { type: 'string' },
57230
+ count: { format: 'float', type: 'number' },
57231
+ credits: {
57232
+ format: 'float',
57233
+ type: 'number',
57234
+ },
57235
+ label: { type: 'string' },
57236
+ },
57237
+ required: [
57238
+ 'billable_action',
57239
+ 'label',
57240
+ 'count',
57241
+ 'credits',
57242
+ ],
57243
+ type: 'object',
57244
+ },
57245
+ type: 'array',
57246
+ },
57247
+ connectivity: {
57248
+ items: {
57249
+ properties: {
57250
+ credits: {
57251
+ format: 'float',
57252
+ type: 'number',
57253
+ },
57254
+ credits_per_device_month: {
57255
+ format: 'float',
57256
+ type: 'number',
57257
+ },
57258
+ device_months: {
57259
+ format: 'float',
57260
+ type: 'number',
57261
+ },
57262
+ label: { type: 'string' },
57263
+ metric: { type: 'string' },
57264
+ },
57265
+ required: [
57266
+ 'metric',
57267
+ 'label',
57268
+ 'device_months',
57269
+ 'credits_per_device_month',
57270
+ 'credits',
57271
+ ],
57272
+ type: 'object',
57273
+ },
57274
+ type: 'array',
57275
+ },
57276
+ credits: { format: 'float', type: 'number' },
57277
+ percent_of_total: {
57278
+ format: 'float',
57279
+ type: 'number',
57280
+ },
57281
+ workspace_id: { nullable: true, type: 'string' },
57282
+ workspace_name: {
57283
+ nullable: true,
57284
+ type: 'string',
57285
+ },
57286
+ },
57287
+ required: [
57288
+ 'workspace_id',
57289
+ 'workspace_name',
57290
+ 'connectivity',
57291
+ 'actions',
57292
+ 'credits',
57293
+ 'percent_of_total',
57294
+ ],
57295
+ type: 'object',
57296
+ },
57297
+ nullable: true,
57298
+ type: 'array',
57299
+ },
57300
+ daily: {
57301
+ items: {
57302
+ properties: {
57303
+ action_credits: {
57304
+ format: 'float',
57305
+ type: 'number',
57306
+ },
57307
+ connectivity_credits: {
57308
+ format: 'float',
57309
+ type: 'number',
57310
+ },
57311
+ date: { type: 'string' },
57312
+ previous_period_credits: {
57313
+ format: 'float',
57314
+ nullable: true,
57315
+ type: 'number',
57316
+ },
57317
+ },
57318
+ required: [
57319
+ 'date',
57320
+ 'connectivity_credits',
57321
+ 'action_credits',
57322
+ 'previous_period_credits',
57323
+ ],
57324
+ type: 'object',
57325
+ },
57326
+ nullable: true,
57327
+ type: 'array',
57328
+ },
57329
+ is_daily_connectivity_included: { type: 'boolean' },
57330
+ package_credits: {
57331
+ format: 'float',
57332
+ nullable: true,
57333
+ type: 'number',
57334
+ },
57335
+ period_ends_at: { format: 'date-time', type: 'string' },
57336
+ period_started_at: {
57337
+ format: 'date-time',
57338
+ type: 'string',
57339
+ },
57340
+ source: {
57341
+ enum: ['metronome', 'estimate'],
57342
+ type: 'string',
57343
+ },
57344
+ used_credits: {
57345
+ format: 'float',
57346
+ nullable: true,
57347
+ type: 'number',
57348
+ },
57349
+ },
57350
+ required: [
57351
+ 'source',
57352
+ 'as_of',
57353
+ 'period_started_at',
57354
+ 'period_ends_at',
57355
+ 'package_credits',
57356
+ 'used_credits',
57357
+ 'by_workspace',
57358
+ 'by_category',
57359
+ 'daily',
57360
+ 'is_daily_connectivity_included',
57361
+ ],
57362
+ type: 'object',
57363
+ },
57364
+ },
57365
+ required: ['usage', 'ok'],
57366
+ type: 'object',
57367
+ },
57368
+ },
57369
+ },
57370
+ description: 'OK',
57371
+ },
57372
+ '400': { description: 'Bad Request' },
57373
+ '401': { description: 'Unauthorized' },
57374
+ },
57375
+ security: [{ console_session_without_workspace: [] }],
57376
+ summary: '/seam/console/v1/credits/usage/get',
57377
+ tags: [],
57378
+ 'x-fern-sdk-group-name': ['seam', 'console', 'v1', 'credits', 'usage'],
57379
+ 'x-fern-sdk-method-name': 'get',
57380
+ 'x-fern-sdk-return-value': 'usage',
57381
+ 'x-response-key': 'usage',
57382
+ 'x-title': "Get an Organization's Credit Usage in Detail",
57383
+ 'x-undocumented': 'Internal endpoint for Console',
57384
+ },
57385
+ },
56765
57386
  '/seam/console/v1/get_resource_locator': {
56766
57387
  get: {
56767
57388
  description: 'Returns the type and system information of a resource given its UUID.',