@deeprelay/sdk 0.1.0 → 0.1.2

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.
Files changed (71) hide show
  1. package/.openapi-generator/FILES +14 -0
  2. package/README.md +13 -2
  3. package/dist/apis/BillingApi.d.ts +53 -0
  4. package/dist/apis/BillingApi.js +141 -0
  5. package/dist/apis/InferenceApi.d.ts +18 -0
  6. package/dist/apis/InferenceApi.js +51 -0
  7. package/dist/esm/apis/BillingApi.d.ts +53 -0
  8. package/dist/esm/apis/BillingApi.js +141 -0
  9. package/dist/esm/apis/InferenceApi.d.ts +18 -0
  10. package/dist/esm/apis/InferenceApi.js +51 -0
  11. package/dist/esm/models/InferencePreflight.d.ts +92 -0
  12. package/dist/esm/models/InferencePreflight.js +86 -0
  13. package/dist/esm/models/RefereeStatus.d.ts +79 -0
  14. package/dist/esm/models/RefereeStatus.js +70 -0
  15. package/dist/esm/models/Referral.d.ts +94 -0
  16. package/dist/esm/models/Referral.js +82 -0
  17. package/dist/esm/models/SubscriptionCheckoutRequest.d.ts +45 -0
  18. package/dist/esm/models/SubscriptionCheckoutRequest.js +45 -0
  19. package/dist/esm/models/SubscriptionCheckoutSession.d.ts +45 -0
  20. package/dist/esm/models/SubscriptionCheckoutSession.js +52 -0
  21. package/dist/esm/models/SubscriptionPortalRequest.d.ts +32 -0
  22. package/dist/esm/models/SubscriptionPortalRequest.js +41 -0
  23. package/dist/esm/models/SubscriptionPortalSession.d.ts +32 -0
  24. package/dist/esm/models/SubscriptionPortalSession.js +43 -0
  25. package/dist/esm/models/VideoJob.d.ts +6 -0
  26. package/dist/esm/models/VideoJob.js +2 -0
  27. package/dist/esm/models/index.d.ts +7 -0
  28. package/dist/esm/models/index.js +7 -0
  29. package/dist/esm/runtime.js +1 -1
  30. package/dist/models/InferencePreflight.d.ts +92 -0
  31. package/dist/models/InferencePreflight.js +94 -0
  32. package/dist/models/RefereeStatus.d.ts +79 -0
  33. package/dist/models/RefereeStatus.js +78 -0
  34. package/dist/models/Referral.d.ts +94 -0
  35. package/dist/models/Referral.js +89 -0
  36. package/dist/models/SubscriptionCheckoutRequest.d.ts +45 -0
  37. package/dist/models/SubscriptionCheckoutRequest.js +52 -0
  38. package/dist/models/SubscriptionCheckoutSession.d.ts +45 -0
  39. package/dist/models/SubscriptionCheckoutSession.js +59 -0
  40. package/dist/models/SubscriptionPortalRequest.d.ts +32 -0
  41. package/dist/models/SubscriptionPortalRequest.js +48 -0
  42. package/dist/models/SubscriptionPortalSession.d.ts +32 -0
  43. package/dist/models/SubscriptionPortalSession.js +50 -0
  44. package/dist/models/VideoJob.d.ts +6 -0
  45. package/dist/models/VideoJob.js +2 -0
  46. package/dist/models/index.d.ts +7 -0
  47. package/dist/models/index.js +7 -0
  48. package/dist/runtime.js +1 -1
  49. package/docs/BillingApi.md +220 -0
  50. package/docs/InferenceApi.md +74 -0
  51. package/docs/InferencePreflight.md +47 -0
  52. package/docs/RefereeStatus.md +47 -0
  53. package/docs/Referral.md +55 -0
  54. package/docs/SubscriptionCheckoutRequest.md +39 -0
  55. package/docs/SubscriptionCheckoutSession.md +38 -0
  56. package/docs/SubscriptionPortalRequest.md +35 -0
  57. package/docs/SubscriptionPortalSession.md +34 -0
  58. package/docs/VideoJob.md +2 -0
  59. package/package.json +1 -1
  60. package/src/apis/BillingApi.ts +180 -0
  61. package/src/apis/InferenceApi.ts +67 -0
  62. package/src/models/InferencePreflight.ts +147 -0
  63. package/src/models/RefereeStatus.ts +131 -0
  64. package/src/models/Referral.ts +164 -0
  65. package/src/models/SubscriptionCheckoutRequest.ts +82 -0
  66. package/src/models/SubscriptionCheckoutSession.ts +92 -0
  67. package/src/models/SubscriptionPortalRequest.ts +65 -0
  68. package/src/models/SubscriptionPortalSession.ts +66 -0
  69. package/src/models/VideoJob.ts +8 -0
  70. package/src/models/index.ts +7 -0
  71. package/src/runtime.ts +1 -1
@@ -0,0 +1,66 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * deeprelay Public Developer API
5
+ * Programmatic API for deeprelay. Authenticate with API keys minted from the dashboard. See https://deeprelay.ai/docs for details.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ * Contact: support@deeprelay.ai
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface SubscriptionPortalSession
20
+ */
21
+ export interface SubscriptionPortalSession {
22
+ /**
23
+ * The hosted billing portal — cancel, resume, change payment method, download invoices.
24
+ * @type {string}
25
+ * @memberof SubscriptionPortalSession
26
+ */
27
+ portalUrl: string;
28
+ }
29
+
30
+ /**
31
+ * Check if a given object implements the SubscriptionPortalSession interface.
32
+ */
33
+ export function instanceOfSubscriptionPortalSession(value: object): value is SubscriptionPortalSession {
34
+ if ((!('portalUrl' in (value as Record<string, any>)) && !('portal_url' in (value as Record<string, any>))) || ((value as Record<string, any>)['portalUrl'] === undefined && (value as Record<string, any>)['portal_url'] === undefined)) return false;
35
+ return true;
36
+ }
37
+
38
+ export function SubscriptionPortalSessionFromJSON(json: any): SubscriptionPortalSession {
39
+ return SubscriptionPortalSessionFromJSONTyped(json, false);
40
+ }
41
+
42
+ export function SubscriptionPortalSessionFromJSONTyped(json: any, ignoreDiscriminator: boolean): SubscriptionPortalSession {
43
+ if (json == null) {
44
+ return json;
45
+ }
46
+ return {
47
+
48
+ 'portalUrl': json['portal_url'],
49
+ };
50
+ }
51
+
52
+ export function SubscriptionPortalSessionToJSON(json: any): SubscriptionPortalSession {
53
+ return SubscriptionPortalSessionToJSONTyped(json, false);
54
+ }
55
+
56
+ export function SubscriptionPortalSessionToJSONTyped(value?: SubscriptionPortalSession | null, ignoreDiscriminator: boolean = false): any {
57
+ if (value == null) {
58
+ return value;
59
+ }
60
+
61
+ return {
62
+
63
+ 'portal_url': value['portalUrl'],
64
+ };
65
+ }
66
+
@@ -85,6 +85,12 @@ export interface VideoJob {
85
85
  * @memberof VideoJob
86
86
  */
87
87
  error?: string;
88
+ /**
89
+ * Human-readable reason behind `error`, when the upstream supplied one. `error` classifies the failure, `error_message` explains it (for example a requested duration outside the model's supported range). Sanitized before storage; only ever present alongside `error`.
90
+ * @type {string}
91
+ * @memberof VideoJob
92
+ */
93
+ errorMessage?: string;
88
94
  /**
89
95
  * Final billed cost in cents; present once the job completes (failed/cancelled jobs are never billed).
90
96
  * @type {number}
@@ -152,6 +158,7 @@ export function VideoJobFromJSONTyped(json: any, ignoreDiscriminator: boolean):
152
158
  'completedAt': json['completed_at'] == null ? undefined : json['completed_at'],
153
159
  'expiresAt': json['expires_at'] == null ? undefined : json['expires_at'],
154
160
  'error': json['error'] == null ? undefined : json['error'],
161
+ 'errorMessage': json['error_message'] == null ? undefined : json['error_message'],
155
162
  'costCents': json['cost_cents'] == null ? undefined : json['cost_cents'],
156
163
  };
157
164
  }
@@ -178,6 +185,7 @@ export function VideoJobToJSONTyped(value?: VideoJob | null, ignoreDiscriminator
178
185
  'completed_at': value['completedAt'],
179
186
  'expires_at': value['expiresAt'],
180
187
  'error': value['error'],
188
+ 'error_message': value['errorMessage'],
181
189
  'cost_cents': value['costCents'],
182
190
  };
183
191
  }
@@ -18,6 +18,7 @@ export * from './ImagesGenerationsRequest';
18
18
  export * from './ImagesResponse';
19
19
  export * from './ImagesResponseDataInner';
20
20
  export * from './ImagesResponseUsage';
21
+ export * from './InferencePreflight';
21
22
  export * from './ListDeposits200Response';
22
23
  export * from './Model';
23
24
  export * from './ModelList';
@@ -31,10 +32,16 @@ export * from './OperationError';
31
32
  export * from './OperationResult';
32
33
  export * from './PeakWindow';
33
34
  export * from './Problem';
35
+ export * from './RefereeStatus';
36
+ export * from './Referral';
34
37
  export * from './SpendingLimit';
35
38
  export * from './StreamOptions';
36
39
  export * from './Subscription';
40
+ export * from './SubscriptionCheckoutRequest';
41
+ export * from './SubscriptionCheckoutSession';
37
42
  export * from './SubscriptionPlan';
43
+ export * from './SubscriptionPortalRequest';
44
+ export * from './SubscriptionPortalSession';
38
45
  export * from './SubscriptionPrice';
39
46
  export * from './SubscriptionQuota';
40
47
  export * from './SubscriptionUsage';
package/src/runtime.ts CHANGED
@@ -75,7 +75,7 @@ export class Configuration {
75
75
  }
76
76
 
77
77
  get headers(): HTTPHeaders | undefined {
78
- return { 'User-Agent': 'deeprelay-sdk-ts/0.1.0', ...this.configuration.headers };
78
+ return { 'User-Agent': 'deeprelay-sdk-ts/0.1.2', ...this.configuration.headers };
79
79
  }
80
80
 
81
81
  get credentials(): RequestCredentials | undefined {