@shapediver/sdk.platform-api-sdk-v1 1.14.16 → 1.15.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 (181) hide show
  1. package/LICENSE +7 -7
  2. package/README.md +50 -50
  3. package/dist/SdPlatformErrors.d.ts +77 -77
  4. package/dist/SdPlatformSdk.d.ts +161 -161
  5. package/dist/SdPlatformSdkContext.d.ts +71 -71
  6. package/dist/SdPlatformSdkCreate.d.ts +7 -7
  7. package/dist/ShapeDiverErrors.d.ts +79 -0
  8. package/dist/ShapeDiverErrors.d.ts.map +1 -0
  9. package/dist/ShapeDiverSDK.d.ts +9 -8
  10. package/dist/ShapeDiverSDK.d.ts.map +1 -0
  11. package/dist/ShapeDiverSDKContext.d.ts +47 -0
  12. package/dist/ShapeDiverSDKContext.d.ts.map +1 -0
  13. package/dist/ShapeDiverSDKInstance.d.ts +91 -100
  14. package/dist/ShapeDiverSDKInstance.d.ts.map +1 -0
  15. package/dist/api/RequestId.d.ts +105 -0
  16. package/dist/api/RequestId.d.ts.map +1 -0
  17. package/dist/api/SdPlatformRequestId.d.ts +104 -104
  18. package/dist/api/SdPlatformSdkApi.d.ts +62 -62
  19. package/dist/api/SdPlatformSdkConfig.d.ts +18 -18
  20. package/dist/api/SdPlatformSdkErrorMapping.d.ts +28 -28
  21. package/dist/api/ShapeDiverSDKApi.d.ts +40 -65
  22. package/dist/api/ShapeDiverSDKApi.d.ts.map +1 -0
  23. package/dist/api/ShapeDiverSDKApiErrors.d.ts +7 -0
  24. package/dist/api/ShapeDiverSDKApiErrors.d.ts.map +1 -0
  25. package/dist/api/ShapeDiverSDKConfig.d.ts +7 -0
  26. package/dist/api/ShapeDiverSDKConfig.d.ts.map +1 -0
  27. package/dist/api/ShapeDiverSDKRequestConfig.d.ts +8 -7
  28. package/dist/api/ShapeDiverSDKRequestConfig.d.ts.map +1 -0
  29. package/dist/auth/AuthServiceApi.d.ts +34 -34
  30. package/dist/auth/AuthServiceApi.d.ts.map +1 -0
  31. package/dist/auth/SdPlatformAuthServiceApi.d.ts +58 -58
  32. package/dist/auth/models/AuthRequest.d.ts +13 -12
  33. package/dist/auth/models/AuthRequest.d.ts.map +1 -0
  34. package/dist/auth/models/AuthResponse.d.ts +12 -8
  35. package/dist/auth/models/AuthResponse.d.ts.map +1 -0
  36. package/dist/bundle.js +2753 -2753
  37. package/dist/bundle.node.js +2753 -2753
  38. package/dist/common/FailedRequestError.d.ts +4 -3
  39. package/dist/common/FailedRequestError.d.ts.map +1 -0
  40. package/dist/common/Filter.d.ts +52 -51
  41. package/dist/common/Filter.d.ts.map +1 -0
  42. package/dist/common/FilterBuilder.d.ts +55 -0
  43. package/dist/common/FilterBuilder.d.ts.map +1 -0
  44. package/dist/common/Parameters.d.ts +29 -28
  45. package/dist/common/Parameters.d.ts.map +1 -0
  46. package/dist/common/QueryRequestParameters.d.ts +46 -0
  47. package/dist/common/QueryRequestParameters.d.ts.map +1 -0
  48. package/dist/common/RequestId.d.ts +106 -101
  49. package/dist/common/RequestId.d.ts.map +1 -0
  50. package/dist/common/ShapeDiverSDKContext.d.ts +32 -31
  51. package/dist/common/ShapeDiverSDKContext.d.ts.map +1 -0
  52. package/dist/config/ShapeDiverSDKConfig.d.ts +7 -6
  53. package/dist/config/ShapeDiverSDKConfig.d.ts.map +1 -0
  54. package/dist/index.d.ts +27 -27
  55. package/dist/resources/ResourcesApi.d.ts +84 -80
  56. package/dist/resources/ResourcesApi.d.ts.map +1 -0
  57. package/dist/resources/SdPlatformApiTokenApi.d.ts +18 -18
  58. package/dist/resources/SdPlatformBackendSystemApi.d.ts +17 -17
  59. package/dist/resources/SdPlatformBookmarkApi.d.ts +16 -16
  60. package/dist/resources/SdPlatformChargebeeApi.d.ts +20 -20
  61. package/dist/resources/SdPlatformDomainApi.d.ts +44 -44
  62. package/dist/resources/SdPlatformHttpLogApi.d.ts +15 -15
  63. package/dist/resources/SdPlatformImageApi.d.ts +36 -36
  64. package/dist/resources/SdPlatformModelApi.d.ts +40 -40
  65. package/dist/resources/SdPlatformModelSharingApi.d.ts +48 -48
  66. package/dist/resources/SdPlatformModelTokenApi.d.ts +10 -10
  67. package/dist/resources/SdPlatformModelTransferApi.d.ts +46 -46
  68. package/dist/resources/SdPlatformNotificationApi.d.ts +22 -22
  69. package/dist/resources/SdPlatformOrganizationApi.d.ts +85 -85
  70. package/dist/resources/SdPlatformPolicyApi.d.ts +17 -17
  71. package/dist/resources/SdPlatformSavedStateApi.d.ts +49 -49
  72. package/dist/resources/SdPlatformSavedStateSharingApi.d.ts +49 -49
  73. package/dist/resources/SdPlatformTagApi.d.ts +15 -15
  74. package/dist/resources/SdPlatformUserAnalyticsApi.d.ts +15 -15
  75. package/dist/resources/SdPlatformUserApi.d.ts +73 -73
  76. package/dist/resources/SdPlatformWebhookApi.d.ts +52 -52
  77. package/dist/resources/chargebee/ChargebeeApi.d.ts +18 -17
  78. package/dist/resources/chargebee/ChargebeeApi.d.ts.map +1 -0
  79. package/dist/resources/chargebee/models/ChargebeeRequestsAndModels.d.ts +45 -44
  80. package/dist/resources/chargebee/models/ChargebeeRequestsAndModels.d.ts.map +1 -0
  81. package/dist/resources/commons/FilterBuilder.d.ts +54 -54
  82. package/dist/resources/commons/QueryRequestParameters.d.ts +46 -0
  83. package/dist/resources/commons/QueryRequestParameters.d.ts.map +1 -0
  84. package/dist/resources/commons/ResourcesApi.d.ts +40 -40
  85. package/dist/resources/httplogs/HttpLogApi.d.ts +16 -15
  86. package/dist/resources/httplogs/HttpLogApi.d.ts.map +1 -0
  87. package/dist/resources/httplogs/models.d.ts +15 -14
  88. package/dist/resources/httplogs/models.d.ts.map +1 -0
  89. package/dist/resources/modelSharing/ModelSharingApi.d.ts +50 -49
  90. package/dist/resources/modelSharing/ModelSharingApi.d.ts.map +1 -0
  91. package/dist/resources/modelSharing/models/ModelSharing.d.ts +29 -28
  92. package/dist/resources/modelSharing/models/ModelSharing.d.ts.map +1 -0
  93. package/dist/resources/modelSharing/models/ModelSharingCreate.d.ts +15 -14
  94. package/dist/resources/modelSharing/models/ModelSharingCreate.d.ts.map +1 -0
  95. package/dist/resources/modelTransfers/CreateModelTransferRequest.d.ts +8 -0
  96. package/dist/resources/modelTransfers/CreateModelTransferRequest.d.ts.map +1 -0
  97. package/dist/resources/modelTransfers/ModelTransferApi.d.ts +45 -44
  98. package/dist/resources/modelTransfers/ModelTransferApi.d.ts.map +1 -0
  99. package/dist/resources/models/ModelApi.d.ts +17 -16
  100. package/dist/resources/models/ModelApi.d.ts.map +1 -0
  101. package/dist/resources/models/models/CreateModelTransferRequest.d.ts +8 -7
  102. package/dist/resources/models/models/CreateModelTransferRequest.d.ts.map +1 -0
  103. package/dist/resources/models/models/Model.d.ts +166 -166
  104. package/dist/resources/models/models/Model.d.ts.map +1 -0
  105. package/dist/resources/models/models/ModelCreate.d.ts +21 -20
  106. package/dist/resources/models/models/ModelCreate.d.ts.map +1 -0
  107. package/dist/resources/models/models/ModelPatch.d.ts +25 -24
  108. package/dist/resources/models/models/ModelPatch.d.ts.map +1 -0
  109. package/dist/resources/notifications/NotificationsApi.d.ts +13 -14
  110. package/dist/resources/notifications/NotificationsApi.d.ts.map +1 -0
  111. package/dist/resources/notifications/models/Notification.d.ts +62 -60
  112. package/dist/resources/notifications/models/Notification.d.ts.map +1 -0
  113. package/dist/resources/notifications/models/Requests.d.ts +19 -18
  114. package/dist/resources/notifications/models/Requests.d.ts.map +1 -0
  115. package/dist/resources/organizations/OrganizationsApi.d.ts +73 -72
  116. package/dist/resources/organizations/OrganizationsApi.d.ts.map +1 -0
  117. package/dist/resources/organizations/models/Organization.d.ts +79 -78
  118. package/dist/resources/organizations/models/Organization.d.ts.map +1 -0
  119. package/dist/resources/organizations/models/Requests.d.ts +22 -21
  120. package/dist/resources/organizations/models/Requests.d.ts.map +1 -0
  121. package/dist/resources/savedStateSharing/SavedStateSharingsApi.d.ts +50 -49
  122. package/dist/resources/savedStateSharing/SavedStateSharingsApi.d.ts.map +1 -0
  123. package/dist/resources/savedStateSharing/models/SavedStateSharingsModels.d.ts +15 -14
  124. package/dist/resources/savedStateSharing/models/SavedStateSharingsModels.d.ts.map +1 -0
  125. package/dist/resources/savedStateSharing/models/SavedStatesSharingsRequests.d.ts +6 -5
  126. package/dist/resources/savedStateSharing/models/SavedStatesSharingsRequests.d.ts.map +1 -0
  127. package/dist/resources/savedStates/SavedStatesApi.d.ts +44 -43
  128. package/dist/resources/savedStates/SavedStatesApi.d.ts.map +1 -0
  129. package/dist/resources/savedStates/models/SavedStatesModels.d.ts +33 -32
  130. package/dist/resources/savedStates/models/SavedStatesModels.d.ts.map +1 -0
  131. package/dist/resources/savedStates/models/SavedStatesRequests.d.ts +29 -28
  132. package/dist/resources/savedStates/models/SavedStatesRequests.d.ts.map +1 -0
  133. package/dist/resources/userModelSessions/UserModelSessionsApi.d.ts +15 -14
  134. package/dist/resources/userModelSessions/UserModelSessionsApi.d.ts.map +1 -0
  135. package/dist/resources/userModelSessions/models/UserModelSession.d.ts +54 -53
  136. package/dist/resources/userModelSessions/models/UserModelSession.d.ts.map +1 -0
  137. package/dist/resources/webhooks/WebhooksApi.d.ts +51 -50
  138. package/dist/resources/webhooks/WebhooksApi.d.ts.map +1 -0
  139. package/dist/resources/webhooks/models/Requests.d.ts +17 -16
  140. package/dist/resources/webhooks/models/Requests.d.ts.map +1 -0
  141. package/package.json +6 -6
  142. package/dist/auth/models/ShapeDiverAuthRequest.d.ts +0 -12
  143. package/dist/resources/apiTokens/ApiTokenApi.d.ts +0 -16
  144. package/dist/resources/apiTokens/models/ApiToken.d.ts +0 -37
  145. package/dist/resources/apiTokens/models/ApiTokenCreate.d.ts +0 -7
  146. package/dist/resources/apiTokens/models/ApiTokenPatch.d.ts +0 -6
  147. package/dist/resources/apiTokens/models/JustCreatedApiToken.d.ts +0 -5
  148. package/dist/resources/backendSystems/BackendSystemApi.d.ts +0 -14
  149. package/dist/resources/backendSystems/models/BackendSystem.d.ts +0 -25
  150. package/dist/resources/backendSystems/models/BackendSystemCreate.d.ts +0 -21
  151. package/dist/resources/backendSystems/models/BackendSystemPatch.d.ts +0 -17
  152. package/dist/resources/bookmarks/BookmarkApi.d.ts +0 -11
  153. package/dist/resources/bookmarks/models/BookmarkCreate.d.ts +0 -4
  154. package/dist/resources/common/FeaturesModel.d.ts +0 -45
  155. package/dist/resources/domains/DomainApi.d.ts +0 -28
  156. package/dist/resources/domains/models/Domain.d.ts +0 -19
  157. package/dist/resources/domains/models/DomainCreateRequest.d.ts +0 -5
  158. package/dist/resources/domains/models/DomainPatchRequest.d.ts +0 -5
  159. package/dist/resources/images/ImageApi.d.ts +0 -33
  160. package/dist/resources/images/models/Image.d.ts +0 -7
  161. package/dist/resources/images/models/ImageCreate.d.ts +0 -9
  162. package/dist/resources/policies/PoliciesApi.d.ts +0 -15
  163. package/dist/resources/policies/PolicyApi.d.ts +0 -15
  164. package/dist/resources/policies/models/Policy.d.ts +0 -221
  165. package/dist/resources/policies/models/PolicyCreate.d.ts +0 -20
  166. package/dist/resources/policies/models/PolicyPatch.d.ts +0 -18
  167. package/dist/resources/sdmodels/SDModelApi.d.ts +0 -14
  168. package/dist/resources/sdmodels/models/SDModel.d.ts +0 -116
  169. package/dist/resources/sdmodels/models/SDModelCreate.d.ts +0 -20
  170. package/dist/resources/sdmodels/models/SDModelPatch.d.ts +0 -11
  171. package/dist/resources/tags/TagApi.d.ts +0 -10
  172. package/dist/resources/tags/models/Tag.d.ts +0 -14
  173. package/dist/resources/tokens/TokenApi.d.ts +0 -8
  174. package/dist/resources/tokens/models/Token.d.ts +0 -7
  175. package/dist/resources/tokens/models/TokenRequest.d.ts +0 -16
  176. package/dist/resources/users/UserApi.d.ts +0 -49
  177. package/dist/resources/users/models/PasswordResetConfirmRequest.d.ts +0 -6
  178. package/dist/resources/users/models/PatchUserRequest.d.ts +0 -32
  179. package/dist/resources/users/models/RegisterUser.d.ts +0 -7
  180. package/dist/resources/users/models/User.d.ts +0 -104
  181. package/dist/resources/users/models/UserPatchRequest.d.ts +0 -41
package/LICENSE CHANGED
@@ -1,7 +1,7 @@
1
- Copyright 2021 ShapeDiver GmbH
2
-
3
- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
-
5
- The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
6
-
7
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1
+ Copyright 2021 ShapeDiver GmbH
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
+
5
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
6
+
7
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
package/README.md CHANGED
@@ -1,50 +1,50 @@
1
- <p style="text-align: center">
2
- <a href="https://www.shapediver.com/">
3
- <img
4
- alt="ShapeDiver"
5
- src="https://sduse1-assets.shapediver.com/production/assets/img/apple-icon.png"
6
- />
7
- </a>
8
- </p>
9
-
10
- # ShapeDiver Platform SDK
11
- [ShapeDiver](https://www.shapediver.com/) is a cloud platform that provides the right tools and scalable infrastructure to help you transform your Grasshopper files into online applications. It allows you to share the power of Grasshopper and Parametric Design with partners, clients and other key stakeholders wherever they are.
12
-
13
- The **ShapeDiver Platform SDK** allows to access the functionality of the [ShapeDiver Platform](https://www.shapediver.com/app/) (or white labelled instances of it) by means of the [ShapeDiver Platform API](https://app.shapediver.com/api/documentation).
14
- The SDK exposes all TypeScript-types describing request and response objects.
15
-
16
- The authentication system is based on **JWT tokens**, which the SDK allows you to request from the **ShapeDiver Platform** using the OAuth 2.0 functionality integrated with the [ShapeDiver Platform API](https://app.shapediver.com/api/documentation).
17
-
18
- ## Usage
19
-
20
- * Add npm package:
21
- ```sh
22
- npm i @shapediver/sdk.platform-api-sdk-v1
23
- ```
24
- * Import constructor function:
25
- ```javascript
26
- import { create } from '@shapediver/sdk.platform-api-sdk-v1';
27
- ```
28
-
29
- * Create and authorize client:
30
- ```javascript
31
- const client = create({clientId: "CLIENT_ID", baseUrl: "SHAPEDIVER_PLATFORM_API_ENDPOINT"});
32
- await client.authorization.passwordGrant("USERNAME", "PASSWORD");
33
- ```
34
-
35
- ## Versioning
36
- We take care to provide backwards compatibility for older versions of the SDK and the API, but might introduce breaking changes in case of major version upgrades.
37
- New features of the SDK might be limited to newer versions of the API. We recommend always using the newest SDK version out there.
38
-
39
- ## Support
40
-
41
- * [Plaform Backend documentation](https://help.shapediver.com/doc/Platform-Backend.1863876635.html)
42
- * [ShapeDiver Help Center](https://help.shapediver.com)
43
- * [Forum](https://forum.shapediver.com)
44
-
45
- If you have further questions, [reach out to us](https://www.shapediver.com/?open_contact=true).
46
-
47
- Find out more about ShapeDiver [right here](https://www.shapediver.com/)!
48
-
49
- ## Licensing
50
- The ShapeDiver Platform SDK is released under the [MIT License](LICENSE).
1
+ <p style="text-align: center">
2
+ <a href="https://www.shapediver.com/">
3
+ <img
4
+ alt="ShapeDiver"
5
+ src="https://sduse1-assets.shapediver.com/production/assets/img/apple-icon.png"
6
+ />
7
+ </a>
8
+ </p>
9
+
10
+ # ShapeDiver Platform SDK
11
+ [ShapeDiver](https://www.shapediver.com/) is a cloud platform that provides the right tools and scalable infrastructure to help you transform your Grasshopper files into online applications. It allows you to share the power of Grasshopper and Parametric Design with partners, clients and other key stakeholders wherever they are.
12
+
13
+ The **ShapeDiver Platform SDK** allows to access the functionality of the [ShapeDiver Platform](https://www.shapediver.com/app/) (or white labelled instances of it) by means of the [ShapeDiver Platform API](https://app.shapediver.com/api/documentation).
14
+ The SDK exposes all TypeScript-types describing request and response objects.
15
+
16
+ The authentication system is based on **JWT tokens**, which the SDK allows you to request from the **ShapeDiver Platform** using the OAuth 2.0 functionality integrated with the [ShapeDiver Platform API](https://app.shapediver.com/api/documentation).
17
+
18
+ ## Usage
19
+
20
+ * Add npm package:
21
+ ```sh
22
+ npm i @shapediver/sdk.platform-api-sdk-v1
23
+ ```
24
+ * Import constructor function:
25
+ ```javascript
26
+ import { create } from '@shapediver/sdk.platform-api-sdk-v1';
27
+ ```
28
+
29
+ * Create and authorize client:
30
+ ```javascript
31
+ const client = create({clientId: "CLIENT_ID", baseUrl: "SHAPEDIVER_PLATFORM_API_ENDPOINT"});
32
+ await client.authorization.passwordGrant("USERNAME", "PASSWORD");
33
+ ```
34
+
35
+ ## Versioning
36
+ We take care to provide backwards compatibility for older versions of the SDK and the API, but might introduce breaking changes in case of major version upgrades.
37
+ New features of the SDK might be limited to newer versions of the API. We recommend always using the newest SDK version out there.
38
+
39
+ ## Support
40
+
41
+ * [Plaform Backend documentation](https://help.shapediver.com/doc/Platform-Backend.1863876635.html)
42
+ * [ShapeDiver Help Center](https://help.shapediver.com)
43
+ * [Forum](https://forum.shapediver.com)
44
+
45
+ If you have further questions, [reach out to us](https://www.shapediver.com/?open_contact=true).
46
+
47
+ Find out more about ShapeDiver [right here](https://www.shapediver.com/)!
48
+
49
+ ## Licensing
50
+ The ShapeDiver Platform SDK is released under the [MIT License](LICENSE).
@@ -1,78 +1,78 @@
1
- /**
2
- * Generic error
3
- */
4
- export declare class SdPlatformError extends Error {
5
- constructor(message: string);
6
- }
7
- /**
8
- * Request error (request could not be sent etc)
9
- */
10
- export declare class SdPlatformRequestError extends SdPlatformError {
11
- readonly desc: string;
12
- constructor(message: string, desc: string);
13
- }
14
- /**
15
- * Generic response error
16
- */
17
- export declare abstract class SdPlatformResponseError extends SdPlatformError {
18
- readonly http_status_code: number;
19
- constructor(message: string, http_status_code: number);
20
- }
21
- /**
22
- * Resource response error
23
- */
24
- export declare class SdPlatformResourceResponseError extends SdPlatformResponseError {
25
- readonly error: string;
26
- readonly error_description: string;
27
- readonly error_uri?: string | undefined;
28
- readonly code?: string | number | undefined;
29
- readonly fields?: {
30
- [key: string]: string[];
31
- } | undefined;
32
- constructor(message: string, http_status_code: number, error: string, error_description: string, error_uri?: string | undefined, code?: string | number | undefined, fields?: {
33
- [key: string]: string[];
34
- } | undefined);
35
- }
36
- /**
37
- * Authentication response error.
38
- * Follows principles of OAuth 2.0
39
- * Please see https://datatracker.ietf.org/doc/html/rfc6749#section-4.1.2.1
40
- */
41
- export declare class SdPlatformOAuthResponseError extends SdPlatformResponseError {
42
- /**
43
- * required error code
44
- *
45
- * * invalid_request
46
- * * unauthorized_client
47
- * * access_denied
48
- * * unsupported_response_type
49
- * * invalid_scope
50
- * * server_error
51
- * * temporarily_unavailable
52
- */
53
- readonly error: string;
54
- /** optional human-readable text providing additional information */
55
- readonly error_description: string;
56
- /** optional URI identifying a human-readable web page with
57
- information about the error */
58
- readonly error_uri?: string | undefined;
59
- constructor(message: string, http_status_code: number,
60
- /**
61
- * required error code
62
- *
63
- * * invalid_request
64
- * * unauthorized_client
65
- * * access_denied
66
- * * unsupported_response_type
67
- * * invalid_scope
68
- * * server_error
69
- * * temporarily_unavailable
70
- */
71
- error: string,
72
- /** optional human-readable text providing additional information */
73
- error_description: string,
74
- /** optional URI identifying a human-readable web page with
75
- information about the error */
76
- error_uri?: string | undefined);
77
- }
1
+ /**
2
+ * Generic error
3
+ */
4
+ export declare class SdPlatformError extends Error {
5
+ constructor(message: string);
6
+ }
7
+ /**
8
+ * Request error (request could not be sent etc)
9
+ */
10
+ export declare class SdPlatformRequestError extends SdPlatformError {
11
+ readonly desc: string;
12
+ constructor(message: string, desc: string);
13
+ }
14
+ /**
15
+ * Generic response error
16
+ */
17
+ export declare abstract class SdPlatformResponseError extends SdPlatformError {
18
+ readonly http_status_code: number;
19
+ constructor(message: string, http_status_code: number);
20
+ }
21
+ /**
22
+ * Resource response error
23
+ */
24
+ export declare class SdPlatformResourceResponseError extends SdPlatformResponseError {
25
+ readonly error: string;
26
+ readonly error_description: string;
27
+ readonly error_uri?: string | undefined;
28
+ readonly code?: string | number | undefined;
29
+ readonly fields?: {
30
+ [key: string]: string[];
31
+ } | undefined;
32
+ constructor(message: string, http_status_code: number, error: string, error_description: string, error_uri?: string | undefined, code?: string | number | undefined, fields?: {
33
+ [key: string]: string[];
34
+ } | undefined);
35
+ }
36
+ /**
37
+ * Authentication response error.
38
+ * Follows principles of OAuth 2.0
39
+ * Please see https://datatracker.ietf.org/doc/html/rfc6749#section-4.1.2.1
40
+ */
41
+ export declare class SdPlatformOAuthResponseError extends SdPlatformResponseError {
42
+ /**
43
+ * required error code
44
+ *
45
+ * * invalid_request
46
+ * * unauthorized_client
47
+ * * access_denied
48
+ * * unsupported_response_type
49
+ * * invalid_scope
50
+ * * server_error
51
+ * * temporarily_unavailable
52
+ */
53
+ readonly error: string;
54
+ /** optional human-readable text providing additional information */
55
+ readonly error_description: string;
56
+ /** optional URI identifying a human-readable web page with
57
+ information about the error */
58
+ readonly error_uri?: string | undefined;
59
+ constructor(message: string, http_status_code: number,
60
+ /**
61
+ * required error code
62
+ *
63
+ * * invalid_request
64
+ * * unauthorized_client
65
+ * * access_denied
66
+ * * unsupported_response_type
67
+ * * invalid_scope
68
+ * * server_error
69
+ * * temporarily_unavailable
70
+ */
71
+ error: string,
72
+ /** optional human-readable text providing additional information */
73
+ error_description: string,
74
+ /** optional URI identifying a human-readable web page with
75
+ information about the error */
76
+ error_uri?: string | undefined);
77
+ }
78
78
  //# sourceMappingURL=SdPlatformErrors.d.ts.map
@@ -1,162 +1,162 @@
1
- import { SdPlatformRequestFinishedEvent, SdPlatformRequestStartEvent } from "./api/SdPlatformSdkApi";
2
- import { SdPlatformSdkConfig } from "./api/SdPlatformSdkConfig";
3
- import { SdPlatformAuthServiceApi } from './auth/SdPlatformAuthServiceApi';
4
- import { SdPlatformApiTokenApi } from "./resources/SdPlatformApiTokenApi";
5
- import { SdPlatformBackendSystemApi } from "./resources/SdPlatformBackendSystemApi";
6
- import { SdPlatformBookmarkApi } from "./resources/SdPlatformBookmarkApi";
7
- import { SdPlatformChargebeeApi } from "./resources/SdPlatformChargebeeApi";
8
- import { SdPlatformDomainApi } from "./resources/SdPlatformDomainApi";
9
- import { SdPlatformHttpLogApi } from './resources/SdPlatformHttpLogApi';
10
- import { SdPlatformImageApi } from "./resources/SdPlatformImageApi";
11
- import { SdPlatformModelApi } from "./resources/SdPlatformModelApi";
12
- import { SdPlatformModelSharingApi } from "./resources/SdPlatformModelSharingApi";
13
- import { SdPlatformModelTokenApi } from "./resources/SdPlatformModelTokenApi";
14
- import { SdPlatformModelTransferApi } from './resources/SdPlatformModelTransferApi';
15
- import { SdPlatformNotificationApi } from "./resources/SdPlatformNotificationApi";
16
- import { SdPlatformOrganizationApi } from "./resources/SdPlatformOrganizationApi";
17
- import { SdPlatformPolicyApi } from "./resources/SdPlatformPolicyApi";
18
- import { SdPlatformSavedStateApi } from './resources/SdPlatformSavedStateApi';
19
- import { SdPlatformSavedStateSharingApi } from "./resources/SdPlatformSavedStateSharingApi";
20
- import { SdPlatformTagApi } from "./resources/SdPlatformTagApi";
21
- import { SdPlatformUserAnalyticsApi } from "./resources/SdPlatformUserAnalyticsApi";
22
- import { SdPlatformUserApi } from "./resources/SdPlatformUserApi";
23
- import { SdPlatformWebhookApi } from './resources/SdPlatformWebhookApi';
24
- export declare class SdPlatformSdk {
25
- private __config;
26
- private __api;
27
- private __authorization;
28
- private __api_tokens;
29
- private __backendSystem;
30
- private __bookmarks;
31
- private __chargebee;
32
- private __domains;
33
- private __http_logs;
34
- private __images;
35
- private __model_sharing;
36
- private __models;
37
- private __modelTokens;
38
- private __modelTransfers;
39
- private __notifications;
40
- private __organizations;
41
- private __policies;
42
- private __savedStates;
43
- private __savedStateSharing;
44
- private __tags;
45
- private __userAnalytics;
46
- private __users;
47
- private __webhooks;
48
- /**
49
- * ShapeDiverSDK constructor
50
- * @param clientId - the client id
51
- * @param clientSecret - the client secret
52
- * @param baseUrl - the base url
53
- */
54
- constructor(clientId?: string | null, clientSecret?: string | null, baseUrl?: string | null);
55
- /**
56
- * Configuration for this instance of the Platform SDK.
57
- */
58
- get config(): SdPlatformSdkConfig;
59
- /**
60
- * Authentication service for ShapeDiver Platform.
61
- */
62
- get authorization(): SdPlatformAuthServiceApi;
63
- /**
64
- * CRUD operations for Platform API tokens.
65
- * Platform API tokens can be limited in scope and lifetime.
66
- * Use Platform API tokens for applications making use of the Platform API.
67
- * Limit their scope as much as possible.
68
- */
69
- get apiTokens(): SdPlatformApiTokenApi;
70
- /**
71
- * Operations for ShapeDiver Geometry Backend Systems known by the Platform Backend.
72
- */
73
- get backendSystem(): SdPlatformBackendSystemApi;
74
- /**
75
- * Operations for creating and deleting bookmarks
76
- */
77
- get bookmarks(): SdPlatformBookmarkApi;
78
- /**
79
- * Actions related to Chargebee subscription management.
80
- */
81
- get chargebee(): SdPlatformChargebeeApi;
82
- /**
83
- * Operations for domains which can be attached to users, organizations, models.
84
- */
85
- get domains(): SdPlatformDomainApi;
86
- /**
87
- * HTTP logs.
88
- */
89
- get httpLogs(): SdPlatformHttpLogApi;
90
- /**
91
- * Operations for images which can be attached to models
92
- */
93
- get images(): SdPlatformImageApi;
94
- /**
95
- * Operations for model sharing relationships.
96
- */
97
- get modelSharing(): SdPlatformModelSharingApi;
98
- /**
99
- * Operations for models on the ShapeDiver Platform.
100
- */
101
- get models(): SdPlatformModelApi;
102
- /**
103
- * Operations for creating tokens for models on Geometry Backend Systems
104
- */
105
- get modelTokens(): SdPlatformModelTokenApi;
106
- /**
107
- * Operations for creating, revoking, accepting, denying, model ownership transfer notifications.
108
- */
109
- get modelTransfers(): SdPlatformModelTransferApi;
110
- /**
111
- * Operations for querying, reading/unreading, creating notifications.
112
- */
113
- get notifications(): SdPlatformNotificationApi;
114
- /**
115
- * Operations for organizations.
116
- */
117
- get organizations(): SdPlatformOrganizationApi;
118
- /**
119
- * Operations for policies.
120
- */
121
- get policies(): SdPlatformPolicyApi;
122
- /**
123
- * Operations for saved states.
124
- */
125
- get savedStates(): SdPlatformSavedStateApi;
126
- /**
127
- * Operations for saved state sharing relationships.
128
- */
129
- get savedStateSharing(): SdPlatformSavedStateSharingApi;
130
- /**
131
- * Operations for tags which can be attached to models.
132
- */
133
- get tags(): SdPlatformTagApi;
134
- /**
135
- * Analytics for users.
136
- */
137
- get userAnalytics(): SdPlatformUserAnalyticsApi;
138
- /**
139
- * Operations for users.
140
- */
141
- get users(): SdPlatformUserApi;
142
- /**
143
- * Webhook calls.
144
- */
145
- get webhooks(): SdPlatformWebhookApi;
146
- /**
147
- * Register callbacks for request start events.
148
- * onRequestStart is fired before each request. This does not modify request, it is used only as notification that request is starting.
149
- * NOTE: requestParams is as shallow copy.
150
- * @param cb
151
- */
152
- onRequestStart(cb: (event: SdPlatformRequestStartEvent) => void): void;
153
- /**
154
- * Register callbacks for request finished events.
155
- * onRequestFinished is fired after request has been resolved.
156
- * NOTE: response is passed as shallow copy.
157
- * NOTE: requestParams is as shallow copy.
158
- * @param cb
159
- */
160
- onRequestFinished(cb: (event: SdPlatformRequestFinishedEvent) => void): void;
161
- }
1
+ import { SdPlatformRequestFinishedEvent, SdPlatformRequestStartEvent } from "./api/SdPlatformSdkApi";
2
+ import { SdPlatformSdkConfig } from "./api/SdPlatformSdkConfig";
3
+ import { SdPlatformAuthServiceApi } from './auth/SdPlatformAuthServiceApi';
4
+ import { SdPlatformApiTokenApi } from "./resources/SdPlatformApiTokenApi";
5
+ import { SdPlatformBackendSystemApi } from "./resources/SdPlatformBackendSystemApi";
6
+ import { SdPlatformBookmarkApi } from "./resources/SdPlatformBookmarkApi";
7
+ import { SdPlatformChargebeeApi } from "./resources/SdPlatformChargebeeApi";
8
+ import { SdPlatformDomainApi } from "./resources/SdPlatformDomainApi";
9
+ import { SdPlatformHttpLogApi } from './resources/SdPlatformHttpLogApi';
10
+ import { SdPlatformImageApi } from "./resources/SdPlatformImageApi";
11
+ import { SdPlatformModelApi } from "./resources/SdPlatformModelApi";
12
+ import { SdPlatformModelSharingApi } from "./resources/SdPlatformModelSharingApi";
13
+ import { SdPlatformModelTokenApi } from "./resources/SdPlatformModelTokenApi";
14
+ import { SdPlatformModelTransferApi } from './resources/SdPlatformModelTransferApi';
15
+ import { SdPlatformNotificationApi } from "./resources/SdPlatformNotificationApi";
16
+ import { SdPlatformOrganizationApi } from "./resources/SdPlatformOrganizationApi";
17
+ import { SdPlatformPolicyApi } from "./resources/SdPlatformPolicyApi";
18
+ import { SdPlatformSavedStateApi } from './resources/SdPlatformSavedStateApi';
19
+ import { SdPlatformSavedStateSharingApi } from "./resources/SdPlatformSavedStateSharingApi";
20
+ import { SdPlatformTagApi } from "./resources/SdPlatformTagApi";
21
+ import { SdPlatformUserAnalyticsApi } from "./resources/SdPlatformUserAnalyticsApi";
22
+ import { SdPlatformUserApi } from "./resources/SdPlatformUserApi";
23
+ import { SdPlatformWebhookApi } from './resources/SdPlatformWebhookApi';
24
+ export declare class SdPlatformSdk {
25
+ private __config;
26
+ private __api;
27
+ private __authorization;
28
+ private __api_tokens;
29
+ private __backendSystem;
30
+ private __bookmarks;
31
+ private __chargebee;
32
+ private __domains;
33
+ private __http_logs;
34
+ private __images;
35
+ private __model_sharing;
36
+ private __models;
37
+ private __modelTokens;
38
+ private __modelTransfers;
39
+ private __notifications;
40
+ private __organizations;
41
+ private __policies;
42
+ private __savedStates;
43
+ private __savedStateSharing;
44
+ private __tags;
45
+ private __userAnalytics;
46
+ private __users;
47
+ private __webhooks;
48
+ /**
49
+ * ShapeDiverSDK constructor
50
+ * @param clientId - the client id
51
+ * @param clientSecret - the client secret
52
+ * @param baseUrl - the base url
53
+ */
54
+ constructor(clientId?: string | null, clientSecret?: string | null, baseUrl?: string | null);
55
+ /**
56
+ * Configuration for this instance of the Platform SDK.
57
+ */
58
+ get config(): SdPlatformSdkConfig;
59
+ /**
60
+ * Authentication service for ShapeDiver Platform.
61
+ */
62
+ get authorization(): SdPlatformAuthServiceApi;
63
+ /**
64
+ * CRUD operations for Platform API tokens.
65
+ * Platform API tokens can be limited in scope and lifetime.
66
+ * Use Platform API tokens for applications making use of the Platform API.
67
+ * Limit their scope as much as possible.
68
+ */
69
+ get apiTokens(): SdPlatformApiTokenApi;
70
+ /**
71
+ * Operations for ShapeDiver Geometry Backend Systems known by the Platform Backend.
72
+ */
73
+ get backendSystem(): SdPlatformBackendSystemApi;
74
+ /**
75
+ * Operations for creating and deleting bookmarks
76
+ */
77
+ get bookmarks(): SdPlatformBookmarkApi;
78
+ /**
79
+ * Actions related to Chargebee subscription management.
80
+ */
81
+ get chargebee(): SdPlatformChargebeeApi;
82
+ /**
83
+ * Operations for domains which can be attached to users, organizations, models.
84
+ */
85
+ get domains(): SdPlatformDomainApi;
86
+ /**
87
+ * HTTP logs.
88
+ */
89
+ get httpLogs(): SdPlatformHttpLogApi;
90
+ /**
91
+ * Operations for images which can be attached to models
92
+ */
93
+ get images(): SdPlatformImageApi;
94
+ /**
95
+ * Operations for model sharing relationships.
96
+ */
97
+ get modelSharing(): SdPlatformModelSharingApi;
98
+ /**
99
+ * Operations for models on the ShapeDiver Platform.
100
+ */
101
+ get models(): SdPlatformModelApi;
102
+ /**
103
+ * Operations for creating tokens for models on Geometry Backend Systems
104
+ */
105
+ get modelTokens(): SdPlatformModelTokenApi;
106
+ /**
107
+ * Operations for creating, revoking, accepting, denying, model ownership transfer notifications.
108
+ */
109
+ get modelTransfers(): SdPlatformModelTransferApi;
110
+ /**
111
+ * Operations for querying, reading/unreading, creating notifications.
112
+ */
113
+ get notifications(): SdPlatformNotificationApi;
114
+ /**
115
+ * Operations for organizations.
116
+ */
117
+ get organizations(): SdPlatformOrganizationApi;
118
+ /**
119
+ * Operations for policies.
120
+ */
121
+ get policies(): SdPlatformPolicyApi;
122
+ /**
123
+ * Operations for saved states.
124
+ */
125
+ get savedStates(): SdPlatformSavedStateApi;
126
+ /**
127
+ * Operations for saved state sharing relationships.
128
+ */
129
+ get savedStateSharing(): SdPlatformSavedStateSharingApi;
130
+ /**
131
+ * Operations for tags which can be attached to models.
132
+ */
133
+ get tags(): SdPlatformTagApi;
134
+ /**
135
+ * Analytics for users.
136
+ */
137
+ get userAnalytics(): SdPlatformUserAnalyticsApi;
138
+ /**
139
+ * Operations for users.
140
+ */
141
+ get users(): SdPlatformUserApi;
142
+ /**
143
+ * Webhook calls.
144
+ */
145
+ get webhooks(): SdPlatformWebhookApi;
146
+ /**
147
+ * Register callbacks for request start events.
148
+ * onRequestStart is fired before each request. This does not modify request, it is used only as notification that request is starting.
149
+ * NOTE: requestParams is as shallow copy.
150
+ * @param cb
151
+ */
152
+ onRequestStart(cb: (event: SdPlatformRequestStartEvent) => void): void;
153
+ /**
154
+ * Register callbacks for request finished events.
155
+ * onRequestFinished is fired after request has been resolved.
156
+ * NOTE: response is passed as shallow copy.
157
+ * NOTE: requestParams is as shallow copy.
158
+ * @param cb
159
+ */
160
+ onRequestFinished(cb: (event: SdPlatformRequestFinishedEvent) => void): void;
161
+ }
162
162
  //# sourceMappingURL=SdPlatformSdk.d.ts.map