stigg-api-client 6.13.0 → 6.14.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ca7f7496d56241a34e947601f4f2132790220d2e5f992c919deb81c99df08613
4
- data.tar.gz: a6781ae1722b36663f3f45fc5646efee34dd8d7acb831dacd86046749a533b41
3
+ metadata.gz: d0f52c3ae940566fd5008ebbf85c57f4947bb8d1aa159b0394a669a269fa3a71
4
+ data.tar.gz: 53e5c7580139015e8031ce6d5f243091cfc9ce8409545a1b71a1fcd60488d750
5
5
  SHA512:
6
- metadata.gz: 88acf1afc095af9b35dda2f93e2ce9900ddbcddbd061f8e62dbafd2cead0967cdea5ccf44f27388050d94adff5f3f0f4587502be6d72ef36ea3b96cd500f9ffe
7
- data.tar.gz: '086e7403853c4af50acc1cecda339ab23d2be9759d59ea4160523bd1a78dd6eed63beadd6fd14149bd81fd2ed9d9fc594603e1ff0091f7b91da67587ddbcf62d'
6
+ metadata.gz: 9b2358d4572650a3f12cb92008db879a618e3c6d3f575a4bacd1a7c5eca4a80290dd0020d4bd23b4f6a30a2aef373d86fcb856a1fc772594510998533a62c4e0
7
+ data.tar.gz: 07b9f3dc5347279eae48476f452617755f667fd3eab665935213f35ebc75f59d7ec27e040a22c7f2d3287dda748652b84f993e8d45a96d9e7fd9b4176877bf72
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- stigg-api-client (6.13.0)
4
+ stigg-api-client (6.14.0)
5
5
  graphlient (>= 0.6.0, < 1.0)
6
6
  graphql-client (>= 0.19, < 1.0)
7
7
 
@@ -1865,6 +1865,23 @@ module Stigg
1865
1865
  }
1866
1866
  GRAPHQL
1867
1867
 
1868
+ CreditConsumptionResponseFragment = <<~GRAPHQL
1869
+ fragment CreditConsumptionResponseFragment on CreditConsumptionResponse {
1870
+ customerId
1871
+ currencyId
1872
+ resourceId
1873
+ amount
1874
+ timestamp
1875
+ credit {
1876
+ currencyId
1877
+ currentUsage
1878
+ usageLimit
1879
+ usagePeriodEnd
1880
+ timestamp
1881
+ }
1882
+ }
1883
+ GRAPHQL
1884
+
1868
1885
  ScheduleVariablesFragment = <<~GRAPHQL
1869
1886
  fragment ScheduleVariablesFragment on ScheduleVariables {
1870
1887
  __typename
@@ -2418,6 +2435,21 @@ module Stigg
2418
2435
  #{Fragment::ReportUsageFragment}
2419
2436
  GRAPHQL
2420
2437
 
2438
+ ConsumeCredits = <<~GRAPHQL
2439
+ mutation ConsumeCredits($input: ConsumeCreditInput!) {
2440
+ consumeCredits(input: $input) {
2441
+ ...CreditConsumptionResponseFragment
2442
+ }
2443
+ }
2444
+ #{Fragment::CreditConsumptionResponseFragment}
2445
+ GRAPHQL
2446
+
2447
+ ConsumeCreditsAsync = <<~GRAPHQL
2448
+ mutation ConsumeCreditsAsync($input: ConsumeCreditsAsyncInput!) {
2449
+ consumeCreditsAsync(input: $input)
2450
+ }
2451
+ GRAPHQL
2452
+
2421
2453
  ReportEvent = <<~GRAPHQL
2422
2454
  mutation ReportEvent($input: UsageEventsReportInput!) {
2423
2455
  reportEvent(events: $input)
@@ -10552,6 +10552,176 @@
10552
10552
  "enumValues": null,
10553
10553
  "possibleTypes": null
10554
10554
  },
10555
+ {
10556
+ "kind": "INPUT_OBJECT",
10557
+ "name": "ConsumeCreditInput",
10558
+ "description": "A single direct credit consumption from a wallet",
10559
+ "fields": null,
10560
+ "inputFields": [
10561
+ {
10562
+ "name": "amount",
10563
+ "description": "The amount of credits to consume",
10564
+ "type": {
10565
+ "kind": "NON_NULL",
10566
+ "name": null,
10567
+ "ofType": {
10568
+ "kind": "SCALAR",
10569
+ "name": "Float",
10570
+ "ofType": null
10571
+ }
10572
+ },
10573
+ "defaultValue": null,
10574
+ "isDeprecated": false,
10575
+ "deprecationReason": null
10576
+ },
10577
+ {
10578
+ "name": "createdAt",
10579
+ "description": "Optional timestamp the consumption is attributed to",
10580
+ "type": {
10581
+ "kind": "SCALAR",
10582
+ "name": "DateTime",
10583
+ "ofType": null
10584
+ },
10585
+ "defaultValue": null,
10586
+ "isDeprecated": false,
10587
+ "deprecationReason": null
10588
+ },
10589
+ {
10590
+ "name": "currencyId",
10591
+ "description": "The credit currency (custom currency refId) to consume from",
10592
+ "type": {
10593
+ "kind": "NON_NULL",
10594
+ "name": null,
10595
+ "ofType": {
10596
+ "kind": "SCALAR",
10597
+ "name": "String",
10598
+ "ofType": null
10599
+ }
10600
+ },
10601
+ "defaultValue": null,
10602
+ "isDeprecated": false,
10603
+ "deprecationReason": null
10604
+ },
10605
+ {
10606
+ "name": "customerId",
10607
+ "description": "The customer to consume credits from (refId)",
10608
+ "type": {
10609
+ "kind": "NON_NULL",
10610
+ "name": null,
10611
+ "ofType": {
10612
+ "kind": "SCALAR",
10613
+ "name": "String",
10614
+ "ofType": null
10615
+ }
10616
+ },
10617
+ "defaultValue": null,
10618
+ "isDeprecated": false,
10619
+ "deprecationReason": null
10620
+ },
10621
+ {
10622
+ "name": "dimensions",
10623
+ "description": "Optional dimensions describing the consumption",
10624
+ "type": {
10625
+ "kind": "SCALAR",
10626
+ "name": "JSON",
10627
+ "ofType": null
10628
+ },
10629
+ "defaultValue": null,
10630
+ "isDeprecated": false,
10631
+ "deprecationReason": null
10632
+ },
10633
+ {
10634
+ "name": "environmentId",
10635
+ "description": "The unique identifier for the environment",
10636
+ "type": {
10637
+ "kind": "SCALAR",
10638
+ "name": "UUID",
10639
+ "ofType": null
10640
+ },
10641
+ "defaultValue": null,
10642
+ "isDeprecated": false,
10643
+ "deprecationReason": null
10644
+ },
10645
+ {
10646
+ "name": "idempotencyKey",
10647
+ "description": "A unique key used to deduplicate the consumption (required)",
10648
+ "type": {
10649
+ "kind": "NON_NULL",
10650
+ "name": null,
10651
+ "ofType": {
10652
+ "kind": "SCALAR",
10653
+ "name": "String",
10654
+ "ofType": null
10655
+ }
10656
+ },
10657
+ "defaultValue": null,
10658
+ "isDeprecated": false,
10659
+ "deprecationReason": null
10660
+ },
10661
+ {
10662
+ "name": "resourceId",
10663
+ "description": "Optional resource (refId) the consumption is attributed to",
10664
+ "type": {
10665
+ "kind": "SCALAR",
10666
+ "name": "String",
10667
+ "ofType": null
10668
+ },
10669
+ "defaultValue": null,
10670
+ "isDeprecated": false,
10671
+ "deprecationReason": null
10672
+ }
10673
+ ],
10674
+ "interfaces": null,
10675
+ "enumValues": null,
10676
+ "possibleTypes": null
10677
+ },
10678
+ {
10679
+ "kind": "INPUT_OBJECT",
10680
+ "name": "ConsumeCreditsAsyncInput",
10681
+ "description": "Input for consuming credits directly from wallets asynchronously",
10682
+ "fields": null,
10683
+ "inputFields": [
10684
+ {
10685
+ "name": "consumptions",
10686
+ "description": "The credit consumptions to report (up to 1000)",
10687
+ "type": {
10688
+ "kind": "NON_NULL",
10689
+ "name": null,
10690
+ "ofType": {
10691
+ "kind": "LIST",
10692
+ "name": null,
10693
+ "ofType": {
10694
+ "kind": "NON_NULL",
10695
+ "name": null,
10696
+ "ofType": {
10697
+ "kind": "INPUT_OBJECT",
10698
+ "name": "ConsumeCreditInput",
10699
+ "ofType": null
10700
+ }
10701
+ }
10702
+ }
10703
+ },
10704
+ "defaultValue": null,
10705
+ "isDeprecated": false,
10706
+ "deprecationReason": null
10707
+ },
10708
+ {
10709
+ "name": "environmentId",
10710
+ "description": "The unique identifier for the environment",
10711
+ "type": {
10712
+ "kind": "SCALAR",
10713
+ "name": "UUID",
10714
+ "ofType": null
10715
+ },
10716
+ "defaultValue": null,
10717
+ "isDeprecated": false,
10718
+ "deprecationReason": null
10719
+ }
10720
+ ],
10721
+ "interfaces": null,
10722
+ "enumValues": null,
10723
+ "possibleTypes": null
10724
+ },
10555
10725
  {
10556
10726
  "kind": "OBJECT",
10557
10727
  "name": "Coupon",
@@ -14923,6 +15093,105 @@
14923
15093
  ],
14924
15094
  "possibleTypes": null
14925
15095
  },
15096
+ {
15097
+ "kind": "OBJECT",
15098
+ "name": "CreditConsumptionResponse",
15099
+ "description": "Result of a synchronous direct credit consumption",
15100
+ "fields": [
15101
+ {
15102
+ "name": "amount",
15103
+ "description": "The amount of credits consumed",
15104
+ "args": [],
15105
+ "type": {
15106
+ "kind": "NON_NULL",
15107
+ "name": null,
15108
+ "ofType": {
15109
+ "kind": "SCALAR",
15110
+ "name": "Float",
15111
+ "ofType": null
15112
+ }
15113
+ },
15114
+ "isDeprecated": false,
15115
+ "deprecationReason": null
15116
+ },
15117
+ {
15118
+ "name": "credit",
15119
+ "description": "The optimistic credit balance after consumption (when sync credit consumption is enabled)",
15120
+ "args": [],
15121
+ "type": {
15122
+ "kind": "OBJECT",
15123
+ "name": "UsageMeasurementCredit",
15124
+ "ofType": null
15125
+ },
15126
+ "isDeprecated": false,
15127
+ "deprecationReason": null
15128
+ },
15129
+ {
15130
+ "name": "currencyId",
15131
+ "description": "The credit currency (custom currency refId) to consume from",
15132
+ "args": [],
15133
+ "type": {
15134
+ "kind": "NON_NULL",
15135
+ "name": null,
15136
+ "ofType": {
15137
+ "kind": "SCALAR",
15138
+ "name": "String",
15139
+ "ofType": null
15140
+ }
15141
+ },
15142
+ "isDeprecated": false,
15143
+ "deprecationReason": null
15144
+ },
15145
+ {
15146
+ "name": "customerId",
15147
+ "description": "The customer to consume credits from (refId)",
15148
+ "args": [],
15149
+ "type": {
15150
+ "kind": "NON_NULL",
15151
+ "name": null,
15152
+ "ofType": {
15153
+ "kind": "SCALAR",
15154
+ "name": "String",
15155
+ "ofType": null
15156
+ }
15157
+ },
15158
+ "isDeprecated": false,
15159
+ "deprecationReason": null
15160
+ },
15161
+ {
15162
+ "name": "resourceId",
15163
+ "description": "Optional resource (refId) the consumption is attributed to",
15164
+ "args": [],
15165
+ "type": {
15166
+ "kind": "SCALAR",
15167
+ "name": "String",
15168
+ "ofType": null
15169
+ },
15170
+ "isDeprecated": false,
15171
+ "deprecationReason": null
15172
+ },
15173
+ {
15174
+ "name": "timestamp",
15175
+ "description": "The timestamp the consumption was attributed to",
15176
+ "args": [],
15177
+ "type": {
15178
+ "kind": "NON_NULL",
15179
+ "name": null,
15180
+ "ofType": {
15181
+ "kind": "SCALAR",
15182
+ "name": "DateTime",
15183
+ "ofType": null
15184
+ }
15185
+ },
15186
+ "isDeprecated": false,
15187
+ "deprecationReason": null
15188
+ }
15189
+ ],
15190
+ "inputFields": null,
15191
+ "interfaces": [],
15192
+ "enumValues": null,
15193
+ "possibleTypes": null
15194
+ },
14926
15195
  {
14927
15196
  "kind": "OBJECT",
14928
15197
  "name": "CreditEntitlement",
@@ -54919,6 +55188,68 @@
54919
55188
  "isDeprecated": false,
54920
55189
  "deprecationReason": null
54921
55190
  },
55191
+ {
55192
+ "name": "consumeCredits",
55193
+ "description": "Consume credits directly from a wallet (synchronous, low-volume)",
55194
+ "args": [
55195
+ {
55196
+ "name": "input",
55197
+ "description": null,
55198
+ "type": {
55199
+ "kind": "NON_NULL",
55200
+ "name": null,
55201
+ "ofType": {
55202
+ "kind": "INPUT_OBJECT",
55203
+ "name": "ConsumeCreditInput",
55204
+ "ofType": null
55205
+ }
55206
+ },
55207
+ "defaultValue": null,
55208
+ "isDeprecated": false,
55209
+ "deprecationReason": null
55210
+ }
55211
+ ],
55212
+ "type": {
55213
+ "kind": "NON_NULL",
55214
+ "name": null,
55215
+ "ofType": {
55216
+ "kind": "OBJECT",
55217
+ "name": "CreditConsumptionResponse",
55218
+ "ofType": null
55219
+ }
55220
+ },
55221
+ "isDeprecated": false,
55222
+ "deprecationReason": null
55223
+ },
55224
+ {
55225
+ "name": "consumeCreditsAsync",
55226
+ "description": "Consume credits directly from wallets asynchronously (high-volume)",
55227
+ "args": [
55228
+ {
55229
+ "name": "input",
55230
+ "description": null,
55231
+ "type": {
55232
+ "kind": "NON_NULL",
55233
+ "name": null,
55234
+ "ofType": {
55235
+ "kind": "INPUT_OBJECT",
55236
+ "name": "ConsumeCreditsAsyncInput",
55237
+ "ofType": null
55238
+ }
55239
+ },
55240
+ "defaultValue": null,
55241
+ "isDeprecated": false,
55242
+ "deprecationReason": null
55243
+ }
55244
+ ],
55245
+ "type": {
55246
+ "kind": "SCALAR",
55247
+ "name": "String",
55248
+ "ofType": null
55249
+ },
55250
+ "isDeprecated": false,
55251
+ "deprecationReason": null
55252
+ },
54922
55253
  {
54923
55254
  "name": "createAccount",
54924
55255
  "description": "Create a new account",
data/lib/stigg/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Stigg
4
- VERSION = "6.13.0"
4
+ VERSION = "6.14.0"
5
5
  end
data/package.json CHANGED
@@ -1,4 +1,4 @@
1
1
  {
2
2
  "name": "@stigg/api-client-ruby",
3
- "version": "6.13.0"
3
+ "version": "6.14.0"
4
4
  }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stigg-api-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.13.0
4
+ version: 6.14.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stigg
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2026-06-24 00:00:00.000000000 Z
11
+ date: 2026-07-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: graphlient