@api-client/core 0.3.11 → 0.4.1
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.
- package/build/browser.d.ts +10 -8
- package/build/browser.js +11 -7
- package/build/browser.js.map +1 -1
- package/build/index.d.ts +12 -11
- package/build/index.js +9 -9
- package/build/index.js.map +1 -1
- package/build/src/data/JmesparthReader.d.ts +1 -1
- package/build/src/data/JmesparthReader.js +1 -1
- package/build/src/events/models/ProjectEvents.d.ts +1 -1
- package/build/src/events/models/ProjectEvents.js +1 -2
- package/build/src/events/models/ProjectEvents.js.map +1 -1
- package/build/src/lib/transformers/PayloadSerializer.d.ts +2 -2
- package/build/src/lib/transformers/PayloadSerializer.js +3 -3
- package/build/src/lib/transformers/PayloadSerializer.js.map +1 -1
- package/build/src/mocking/ProjectMock.d.ts +7 -1
- package/build/src/mocking/ProjectMock.js +6 -0
- package/build/src/mocking/ProjectMock.js.map +1 -1
- package/build/src/mocking/lib/History.d.ts +70 -0
- package/build/src/mocking/lib/History.js +120 -0
- package/build/src/mocking/lib/History.js.map +1 -0
- package/build/src/mocking/lib/Request.d.ts +2 -2
- package/build/src/mocking/lib/Request.js +3 -2
- package/build/src/mocking/lib/Request.js.map +1 -1
- package/build/src/mocking/lib/Response.d.ts +6 -6
- package/build/src/mocking/lib/Response.js +6 -6
- package/build/src/mocking/lib/Response.js.map +1 -1
- package/build/src/mocking/lib/User.d.ts +20 -0
- package/build/src/mocking/lib/User.js +54 -0
- package/build/src/mocking/lib/User.js.map +1 -0
- package/build/src/models/AuthorizationData.d.ts +2 -2
- package/build/src/models/AuthorizationData.js +2 -2
- package/build/src/models/Backend.d.ts +85 -0
- package/build/src/models/ClientCertificate.d.ts +1 -1
- package/build/src/models/Environment.d.ts +3 -3
- package/build/src/models/Environment.js +3 -3
- package/build/src/models/Environment.js.map +1 -1
- package/build/src/models/ErrorResponse.d.ts +1 -1
- package/build/src/models/ErrorResponse.js +1 -1
- package/build/src/models/HostRule.d.ts +4 -4
- package/build/src/models/HostRule.js +4 -4
- package/build/src/models/HostRule.js.map +1 -1
- package/build/src/models/HttpHistory.d.ts +64 -18
- package/build/src/models/HttpHistory.js +43 -19
- package/build/src/models/HttpHistory.js.map +1 -1
- package/build/src/models/HttpProject.d.ts +4 -5
- package/build/src/models/HttpProject.js +3 -3
- package/build/src/models/HttpProject.js.map +1 -1
- package/build/src/models/HttpProjectListItem.d.ts +1 -1
- package/build/src/models/HttpProjectListItem.js +1 -1
- package/build/src/models/HttpProjectListItem.js.map +1 -1
- package/build/src/models/HttpRequest.d.ts +2 -2
- package/build/src/models/HttpRequest.js +2 -2
- package/build/src/models/HttpRequest.js.map +1 -1
- package/build/src/models/HttpResponse.d.ts +2 -2
- package/build/src/models/HttpResponse.js +3 -3
- package/build/src/models/HttpResponse.js.map +1 -1
- package/build/src/models/License.d.ts +3 -3
- package/build/src/models/License.js +3 -3
- package/build/src/models/License.js.map +1 -1
- package/build/src/models/ProjectFolder.d.ts +2 -2
- package/build/src/models/ProjectFolder.js +3 -3
- package/build/src/models/ProjectFolder.js.map +1 -1
- package/build/src/models/ProjectItem.d.ts +1 -1
- package/build/src/models/ProjectItem.js +2 -2
- package/build/src/models/ProjectItem.js.map +1 -1
- package/build/src/models/ProjectRequest.d.ts +2 -2
- package/build/src/models/ProjectRequest.js +1 -1
- package/build/src/models/ProjectRequest.js.map +1 -1
- package/build/src/models/ProjectSchema.d.ts +2 -2
- package/build/src/models/ProjectSchema.js +1 -1
- package/build/src/models/ProjectSchema.js.map +1 -1
- package/build/src/models/Property.d.ts +4 -4
- package/build/src/models/Property.js +4 -4
- package/build/src/models/Property.js.map +1 -1
- package/build/src/models/Provider.d.ts +3 -3
- package/build/src/models/Provider.js +3 -3
- package/build/src/models/Provider.js.map +1 -1
- package/build/src/models/Request.d.ts +2 -2
- package/build/src/models/Request.js +3 -3
- package/build/src/models/Request.js.map +1 -1
- package/build/src/models/RequestActions.d.ts +2 -4
- package/build/src/models/RequestActions.js +2 -4
- package/build/src/models/RequestActions.js.map +1 -1
- package/build/src/models/RequestAuthorization.d.ts +3 -5
- package/build/src/models/RequestAuthorization.js +2 -4
- package/build/src/models/RequestAuthorization.js.map +1 -1
- package/build/src/models/RequestConfig.d.ts +3 -5
- package/build/src/models/RequestConfig.js +1 -3
- package/build/src/models/RequestConfig.js.map +1 -1
- package/build/src/models/RequestLog.d.ts +14 -8
- package/build/src/models/RequestLog.js +18 -7
- package/build/src/models/RequestLog.js.map +1 -1
- package/build/src/models/RequestTime.d.ts +4 -6
- package/build/src/models/RequestTime.js +2 -4
- package/build/src/models/RequestTime.js.map +1 -1
- package/build/src/models/RequestUiMeta.d.ts +5 -5
- package/build/src/models/RequestUiMeta.js +2 -2
- package/build/src/models/RequestUiMeta.js.map +1 -1
- package/build/src/models/RequestsSize.d.ts +1 -3
- package/build/src/models/RequestsSize.js +1 -3
- package/build/src/models/RequestsSize.js.map +1 -1
- package/build/src/models/{ArcResponse.d.ts → Response.d.ts} +7 -9
- package/build/src/models/{ArcResponse.js → Response.js} +4 -6
- package/build/src/models/Response.js.map +1 -0
- package/build/src/models/ResponseAuthorization.d.ts +3 -3
- package/build/src/models/ResponseAuthorization.js +3 -3
- package/build/src/models/ResponseAuthorization.js.map +1 -1
- package/build/src/models/ResponseRedirect.d.ts +3 -5
- package/build/src/models/ResponseRedirect.js +1 -3
- package/build/src/models/ResponseRedirect.js.map +1 -1
- package/build/src/models/RevisionInfo.d.ts +1 -1
- package/build/src/models/RevisionInfo.js +1 -1
- package/build/src/models/RevisionInfo.js.map +1 -1
- package/build/src/models/SentRequest.d.ts +2 -4
- package/build/src/models/SentRequest.js +1 -3
- package/build/src/models/SentRequest.js.map +1 -1
- package/build/src/models/Server.d.ts +3 -3
- package/build/src/models/Server.js +3 -3
- package/build/src/models/Server.js.map +1 -1
- package/build/src/models/Thing.d.ts +3 -3
- package/build/src/models/Thing.js +3 -3
- package/build/src/models/Thing.js.map +1 -1
- package/build/src/models/Url.d.ts +2 -4
- package/build/src/models/Url.js +2 -4
- package/build/src/models/Url.js.map +1 -1
- package/build/src/models/User.d.ts +2 -1
- package/build/src/models/User.js +1 -1
- package/build/src/models/User.js.map +1 -1
- package/build/src/models/WebApi.d.ts +1 -1
- package/build/src/models/WebApi.js +1 -1
- package/build/src/models/WebApi.js.map +1 -1
- package/build/src/models/WebApiIndex.d.ts +1 -1
- package/build/src/models/WebApiIndex.js +1 -1
- package/build/src/models/WebApiIndex.js.map +1 -1
- package/build/src/models/Workspace.d.ts +4 -4
- package/build/src/models/Workspace.js +4 -4
- package/build/src/models/Workspace.js.map +1 -1
- package/build/src/models/actions/Action.d.ts +2 -2
- package/build/src/models/actions/Action.js +1 -1
- package/build/src/models/actions/Action.js.map +1 -1
- package/build/src/models/actions/Condition.d.ts +2 -2
- package/build/src/models/actions/Condition.js +1 -1
- package/build/src/models/actions/Condition.js.map +1 -1
- package/build/src/models/actions/RunnableAction.d.ts +1 -1
- package/build/src/models/actions/RunnableAction.js +1 -1
- package/build/src/models/actions/RunnableAction.js.map +1 -1
- package/build/src/models/actions/runnable/DeleteCookieAction.d.ts +2 -2
- package/build/src/models/actions/runnable/DeleteCookieAction.js +1 -1
- package/build/src/models/actions/runnable/DeleteCookieAction.js.map +1 -1
- package/build/src/models/actions/runnable/SetCookieAction.d.ts +2 -2
- package/build/src/models/actions/runnable/SetCookieAction.js +1 -1
- package/build/src/models/actions/runnable/SetCookieAction.js.map +1 -1
- package/build/src/models/actions/runnable/SetVariableAction.d.ts +2 -2
- package/build/src/models/actions/runnable/SetVariableAction.js +1 -1
- package/build/src/models/actions/runnable/SetVariableAction.js.map +1 -1
- package/build/src/models/transformers/ImportUtils.d.ts +1 -1
- package/build/src/models/transformers/ImportUtils.js +1 -1
- package/build/src/models/transformers/PostmanBackupTransformer.js +2 -1
- package/build/src/models/transformers/PostmanBackupTransformer.js.map +1 -1
- package/build/src/models/transformers/PostmanV21Transformer.js +2 -1
- package/build/src/models/transformers/PostmanV21Transformer.js.map +1 -1
- package/build/src/models/transformers/PostmanV2Transformer.js +2 -1
- package/build/src/models/transformers/PostmanV2Transformer.js.map +1 -1
- package/build/src/runtime/actions/RunnableCondition.d.ts +6 -7
- package/build/src/runtime/actions/RunnableCondition.js +4 -5
- package/build/src/runtime/actions/RunnableCondition.js.map +1 -1
- package/build/src/runtime/http-engine/{ArcEngine.d.ts → CoreEngine.d.ts} +3 -3
- package/build/src/runtime/http-engine/{ArcEngine.js → CoreEngine.js} +8 -8
- package/build/src/runtime/http-engine/CoreEngine.js.map +1 -0
- package/build/src/runtime/http-engine/HttpEngine.d.ts +3 -3
- package/build/src/runtime/http-engine/HttpEngine.js +3 -20
- package/build/src/runtime/http-engine/HttpEngine.js.map +1 -1
- package/build/src/runtime/modules/BasicAuthCache.js +2 -5
- package/build/src/runtime/modules/BasicAuthCache.js.map +1 -1
- package/build/src/runtime/modules/RequestCookies.d.ts +1 -1
- package/build/src/runtime/modules/RequestCookies.js +3 -2
- package/build/src/runtime/modules/RequestCookies.js.map +1 -1
- package/build/src/runtime/node/InteropInterfaces.d.ts +115 -0
- package/build/src/runtime/node/InteropInterfaces.js +2 -0
- package/build/src/runtime/node/InteropInterfaces.js.map +1 -0
- package/build/src/runtime/node/ProjectParallelRunner.d.ts +2 -7
- package/build/src/runtime/node/ProjectParallelRunner.js.map +1 -1
- package/build/src/runtime/node/ProjectRequestRunner.d.ts +17 -49
- package/build/src/runtime/node/ProjectRequestRunner.js +39 -10
- package/build/src/runtime/node/ProjectRequestRunner.js.map +1 -1
- package/build/src/runtime/node/ProjectRunner.d.ts +1 -59
- package/build/src/runtime/node/ProjectRunner.js.map +1 -1
- package/build/src/runtime/node/ProjectRunnerWorker.js.map +1 -1
- package/build/src/runtime/node/RequestFactory.d.ts +1 -1
- package/build/src/runtime/node/RequestFactory.js +3 -3
- package/build/src/runtime/node/RequestFactory.js.map +1 -1
- package/build/src/runtime/reporters/ProjectRunCliReporter.js.map +1 -1
- package/build/src/runtime/reporters/Reporter.js.map +1 -1
- package/build/src/runtime/store/AuthSdk.d.ts +28 -0
- package/build/src/runtime/store/AuthSdk.js +123 -0
- package/build/src/runtime/store/AuthSdk.js.map +1 -0
- package/build/src/runtime/store/BackendSdk.d.ts +8 -0
- package/build/src/runtime/store/BackendSdk.js +25 -0
- package/build/src/runtime/store/BackendSdk.js.map +1 -0
- package/build/src/runtime/store/HistorySdk.d.ts +48 -0
- package/build/src/runtime/store/HistorySdk.js +142 -0
- package/build/src/runtime/store/HistorySdk.js.map +1 -0
- package/build/src/runtime/store/Http.d.ts +14 -0
- package/build/src/runtime/store/Http.js +4 -0
- package/build/src/runtime/store/Http.js.map +1 -0
- package/build/src/runtime/store/HttpNode.d.ts +16 -0
- package/build/src/runtime/store/HttpNode.js +95 -0
- package/build/src/runtime/store/HttpNode.js.map +1 -0
- package/build/src/runtime/store/HttpWeb.d.ts +15 -0
- package/build/src/runtime/store/HttpWeb.js +83 -0
- package/build/src/runtime/store/HttpWeb.js.map +1 -0
- package/build/src/runtime/store/ProjectsSdk.d.ts +43 -0
- package/build/src/runtime/store/ProjectsSdk.js +144 -0
- package/build/src/runtime/store/ProjectsSdk.js.map +1 -0
- package/build/src/runtime/store/RouteBuilder.d.ts +42 -0
- package/build/src/runtime/store/RouteBuilder.js +75 -0
- package/build/src/runtime/store/RouteBuilder.js.map +1 -0
- package/build/src/runtime/store/Sdk.d.ts +79 -0
- package/build/src/runtime/store/Sdk.js +117 -0
- package/build/src/runtime/store/Sdk.js.map +1 -0
- package/build/src/runtime/store/SdkBase.d.ts +45 -0
- package/build/src/runtime/store/SdkBase.js +40 -0
- package/build/src/runtime/store/SdkBase.js.map +1 -0
- package/build/src/runtime/store/SpacesSdk.d.ts +50 -0
- package/build/src/runtime/store/SpacesSdk.js +185 -0
- package/build/src/runtime/store/SpacesSdk.js.map +1 -0
- package/build/src/runtime/store/StoreSdkNode.d.ts +10 -0
- package/build/src/runtime/store/StoreSdkNode.js +11 -0
- package/build/src/runtime/store/StoreSdkNode.js.map +1 -0
- package/build/src/runtime/store/StoreSdkWeb.d.ts +10 -0
- package/build/src/runtime/store/StoreSdkWeb.js +11 -0
- package/build/src/runtime/store/StoreSdkWeb.js.map +1 -0
- package/build/src/runtime/store/UsersSdk.d.ts +18 -0
- package/build/src/runtime/store/UsersSdk.js +88 -0
- package/build/src/runtime/store/UsersSdk.js.map +1 -0
- package/build/src/runtime/store/WsClient.d.ts +24 -0
- package/build/src/runtime/store/WsClient.js +4 -0
- package/build/src/runtime/store/WsClient.js.map +1 -0
- package/build/src/runtime/store/WsClientNode.d.ts +24 -0
- package/build/src/runtime/store/WsClientNode.js +66 -0
- package/build/src/runtime/store/WsClientNode.js.map +1 -0
- package/build/src/runtime/store/WsClientWeb.d.ts +23 -0
- package/build/src/runtime/store/WsClientWeb.js +73 -0
- package/build/src/runtime/store/WsClientWeb.js.map +1 -0
- package/package.json +6 -8
- package/readme.md +5 -5
- package/src/data/JmesparthReader.ts +1 -1
- package/src/events/models/ProjectEvents.ts +2 -2
- package/src/events/readme.md +1 -1
- package/src/lib/transformers/PayloadSerializer.ts +3 -3
- package/src/mocking/ProjectMock.ts +9 -1
- package/src/mocking/lib/History.ts +179 -0
- package/src/mocking/lib/Request.ts +5 -5
- package/src/mocking/lib/Response.ts +10 -10
- package/src/mocking/lib/User.ts +68 -0
- package/src/models/AuthorizationData.ts +2 -2
- package/src/models/Backend.ts +93 -0
- package/src/models/ClientCertificate.ts +1 -1
- package/src/models/Environment.ts +4 -4
- package/src/models/ErrorResponse.ts +1 -1
- package/src/models/HostRule.ts +5 -5
- package/src/models/HttpHistory.ts +89 -27
- package/src/models/HttpProject.ts +5 -6
- package/src/models/HttpProjectListItem.ts +1 -1
- package/src/models/HttpRequest.ts +2 -2
- package/src/models/HttpResponse.ts +3 -3
- package/src/models/License.ts +4 -4
- package/src/models/ProjectFolder.ts +3 -3
- package/src/models/ProjectItem.ts +2 -2
- package/src/models/ProjectRequest.ts +2 -2
- package/src/models/ProjectSchema.ts +2 -2
- package/src/models/Property.ts +5 -5
- package/src/models/Provider.ts +4 -4
- package/src/models/README.md +2 -2
- package/src/models/Request.ts +4 -4
- package/src/models/RequestActions.ts +2 -4
- package/src/models/RequestAuthorization.ts +3 -5
- package/src/models/RequestConfig.ts +3 -5
- package/src/models/RequestLog.ts +25 -11
- package/src/models/RequestTime.ts +4 -6
- package/src/models/RequestUiMeta.ts +5 -5
- package/src/models/RequestsSize.ts +1 -3
- package/src/models/{ArcResponse.ts → Response.ts} +12 -14
- package/src/models/ResponseAuthorization.ts +4 -4
- package/src/models/ResponseRedirect.ts +3 -5
- package/src/models/RevisionInfo.ts +1 -1
- package/src/models/SentRequest.ts +2 -4
- package/src/models/Server.ts +4 -4
- package/src/models/Thing.ts +4 -4
- package/src/models/Url.ts +2 -4
- package/src/models/User.ts +2 -1
- package/src/models/WebApi.ts +1 -1
- package/src/models/WebApiIndex.ts +1 -1
- package/src/models/Workspace.ts +5 -5
- package/src/models/actions/Action.ts +2 -2
- package/src/models/actions/Condition.ts +2 -2
- package/src/models/actions/RunnableAction.ts +1 -1
- package/src/models/actions/runnable/DeleteCookieAction.ts +2 -2
- package/src/models/actions/runnable/SetCookieAction.ts +2 -2
- package/src/models/actions/runnable/SetVariableAction.ts +2 -2
- package/src/models/transformers/ImportUtils.ts +1 -1
- package/src/models/transformers/PostmanBackupTransformer.ts +2 -1
- package/src/models/transformers/PostmanV21Transformer.ts +2 -1
- package/src/models/transformers/PostmanV2Transformer.ts +2 -1
- package/src/runtime/actions/RunnableCondition.ts +6 -7
- package/src/runtime/http-engine/{ArcEngine.ts → CoreEngine.ts} +7 -7
- package/src/runtime/http-engine/HttpEngine.ts +5 -24
- package/src/runtime/modules/BasicAuthCache.ts +2 -6
- package/src/runtime/modules/RequestCookies.ts +6 -5
- package/src/runtime/node/InteropInterfaces.ts +121 -0
- package/src/runtime/node/ProjectParallelRunner.ts +2 -9
- package/src/runtime/node/ProjectRequestRunner.ts +42 -61
- package/src/runtime/node/ProjectRunner.ts +1 -60
- package/src/runtime/node/ProjectRunnerWorker.ts +2 -1
- package/src/runtime/node/RequestFactory.ts +3 -3
- package/src/runtime/reporters/ProjectRunCliReporter.ts +2 -2
- package/src/runtime/reporters/Reporter.ts +4 -4
- package/src/runtime/store/AuthSdk.ts +126 -0
- package/src/runtime/store/BackendSdk.ts +25 -0
- package/src/runtime/store/HistorySdk.ts +157 -0
- package/src/runtime/store/Http.ts +18 -0
- package/src/runtime/store/HttpNode.ts +100 -0
- package/src/runtime/store/HttpWeb.ts +89 -0
- package/src/runtime/store/ProjectsSdk.ts +147 -0
- package/src/runtime/store/RouteBuilder.ts +89 -0
- package/src/runtime/store/Sdk.ts +131 -0
- package/src/runtime/store/SdkBase.ts +72 -0
- package/src/runtime/store/SpacesSdk.ts +190 -0
- package/src/runtime/store/StoreSdkNode.ts +13 -0
- package/src/runtime/store/StoreSdkWeb.ts +13 -0
- package/src/runtime/store/UsersSdk.ts +89 -0
- package/src/runtime/store/WsClient.ts +28 -0
- package/src/runtime/store/WsClientNode.ts +68 -0
- package/src/runtime/store/WsClientWeb.ts +75 -0
- package/build/src/models/ArcResponse.js.map +0 -1
- package/build/src/models/HistoryIndex.d.ts +0 -43
- package/build/src/models/HistoryIndex.js +0 -53
- package/build/src/models/HistoryIndex.js.map +0 -1
- package/build/src/models/HistoryRequest.d.ts +0 -13
- package/build/src/models/HistoryRequest.js +0 -25
- package/build/src/models/HistoryRequest.js.map +0 -1
- package/build/src/runtime/http-engine/ArcEngine.js.map +0 -1
- package/build/src/runtime/http-engine/NodeEngine.d.ts +0 -154
- package/build/src/runtime/http-engine/NodeEngine.js +0 -766
- package/build/src/runtime/http-engine/NodeEngine.js.map +0 -1
- package/build/src/runtime/http-engine/NodeEngineDirect.d.ts +0 -113
- package/build/src/runtime/http-engine/NodeEngineDirect.js +0 -449
- package/build/src/runtime/http-engine/NodeEngineDirect.js.map +0 -1
- package/build/src/runtime/store/StoreSdk.d.ts +0 -279
- package/build/src/runtime/store/StoreSdk.js +0 -840
- package/build/src/runtime/store/StoreSdk.js.map +0 -1
- package/src/models/HistoryIndex.ts +0 -76
- package/src/models/HistoryRequest.ts +0 -28
- package/src/runtime/http-engine/NodeEngine.ts +0 -792
- package/src/runtime/http-engine/NodeEngineDirect.ts +0 -482
- package/src/runtime/store/StoreSdk.ts +0 -895
package/src/models/RequestLog.ts
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { IResponseRedirect, ResponseRedirect } from './ResponseRedirect.js';
|
|
2
2
|
import { ISentRequest, SentRequest } from './SentRequest.js';
|
|
3
3
|
import { IErrorResponse, ErrorResponse } from './ErrorResponse.js';
|
|
4
|
-
import {
|
|
4
|
+
import { IResponse, Response } from './Response.js';
|
|
5
5
|
import { IRequestsSize, RequestsSize } from './RequestsSize.js';
|
|
6
6
|
import { ResponseRedirect as LegacyRedirect } from './legacy/request/ArcResponse.js';
|
|
7
7
|
|
|
8
|
-
export const Kind = '
|
|
8
|
+
export const Kind = 'Core#ResponseLog';
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
11
|
* Describes a request / response pair associated with a request.
|
|
12
12
|
*/
|
|
13
13
|
export interface IRequestLog {
|
|
14
|
-
kind:
|
|
14
|
+
kind: typeof Kind;
|
|
15
15
|
/**
|
|
16
16
|
* Describes an HTTP request sent by the transport.
|
|
17
17
|
*/
|
|
@@ -19,7 +19,7 @@ export interface IRequestLog {
|
|
|
19
19
|
/**
|
|
20
20
|
* The last response made with this request, if any.
|
|
21
21
|
*/
|
|
22
|
-
response?:
|
|
22
|
+
response?: IResponse | IErrorResponse;
|
|
23
23
|
/**
|
|
24
24
|
* The list of redirects, if any.
|
|
25
25
|
*/
|
|
@@ -28,6 +28,10 @@ export interface IRequestLog {
|
|
|
28
28
|
* Request and response size. Some HTTP clients may not give this information.
|
|
29
29
|
*/
|
|
30
30
|
size?: IRequestsSize;
|
|
31
|
+
/**
|
|
32
|
+
* Optional request ID defined on an HTTP project that triggered this log.
|
|
33
|
+
*/
|
|
34
|
+
requestId?: string;
|
|
31
35
|
}
|
|
32
36
|
|
|
33
37
|
/**
|
|
@@ -42,7 +46,7 @@ export class RequestLog {
|
|
|
42
46
|
/**
|
|
43
47
|
* The last response made with this request, if any.
|
|
44
48
|
*/
|
|
45
|
-
response?:
|
|
49
|
+
response?: Response | ErrorResponse;
|
|
46
50
|
/**
|
|
47
51
|
* The list of redirects, if any.
|
|
48
52
|
*/
|
|
@@ -51,6 +55,10 @@ export class RequestLog {
|
|
|
51
55
|
* Request and response size. Some HTTP clients may not give this information.
|
|
52
56
|
*/
|
|
53
57
|
size?: RequestsSize;
|
|
58
|
+
/**
|
|
59
|
+
* Optional request ID defined on an HTTP project that triggered this log.
|
|
60
|
+
*/
|
|
61
|
+
requestId?: string;
|
|
54
62
|
|
|
55
63
|
static fromRequest(request: ISentRequest): RequestLog {
|
|
56
64
|
return new RequestLog({
|
|
@@ -59,7 +67,7 @@ export class RequestLog {
|
|
|
59
67
|
});
|
|
60
68
|
}
|
|
61
69
|
|
|
62
|
-
static fromRequestResponse(request: ISentRequest, response:
|
|
70
|
+
static fromRequestResponse(request: ISentRequest, response: IResponse | IErrorResponse): RequestLog {
|
|
63
71
|
return new RequestLog({
|
|
64
72
|
kind: Kind,
|
|
65
73
|
request,
|
|
@@ -86,20 +94,18 @@ export class RequestLog {
|
|
|
86
94
|
|
|
87
95
|
/**
|
|
88
96
|
* Creates a new response clearing anything that is so far defined.
|
|
89
|
-
*
|
|
90
|
-
* Note, this throws an error when the object is not an ARC response.
|
|
91
97
|
*/
|
|
92
98
|
new(init: IRequestLog): void {
|
|
93
|
-
const { request, response, redirects, size } = init;
|
|
99
|
+
const { request, response, redirects, size, requestId } = init;
|
|
94
100
|
this.kind = Kind;
|
|
95
101
|
if (request) {
|
|
96
102
|
this.request = new SentRequest(request);
|
|
97
103
|
}
|
|
98
104
|
if (response) {
|
|
99
|
-
if (
|
|
105
|
+
if (Response.isErrorResponse(response)) {
|
|
100
106
|
this.response = new ErrorResponse(response as IErrorResponse);
|
|
101
107
|
} else {
|
|
102
|
-
this.response = new
|
|
108
|
+
this.response = new Response(response as IResponse);
|
|
103
109
|
}
|
|
104
110
|
} else {
|
|
105
111
|
this.response = undefined;
|
|
@@ -114,6 +120,11 @@ export class RequestLog {
|
|
|
114
120
|
} else {
|
|
115
121
|
this.size = undefined;
|
|
116
122
|
}
|
|
123
|
+
if (requestId) {
|
|
124
|
+
this.requestId = requestId;
|
|
125
|
+
} else {
|
|
126
|
+
this.requestId = undefined;
|
|
127
|
+
}
|
|
117
128
|
}
|
|
118
129
|
|
|
119
130
|
toJSON(): IRequestLog {
|
|
@@ -132,6 +143,9 @@ export class RequestLog {
|
|
|
132
143
|
if (this.response) {
|
|
133
144
|
result.response = this.response.toJSON();
|
|
134
145
|
}
|
|
146
|
+
if (this.requestId) {
|
|
147
|
+
result.requestId = this.requestId;
|
|
148
|
+
}
|
|
135
149
|
return result;
|
|
136
150
|
}
|
|
137
151
|
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
export const Kind = '
|
|
1
|
+
export const Kind = 'Core#RequestTime';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
|
-
* Schema definition for
|
|
4
|
+
* Schema definition for API Client request timings. This is mostly consistent with HAR timings.
|
|
5
5
|
*/
|
|
6
6
|
export interface IRequestTime {
|
|
7
|
-
kind?:
|
|
7
|
+
kind?: typeof Kind;
|
|
8
8
|
connect: number;
|
|
9
9
|
receive: number;
|
|
10
10
|
send: number;
|
|
@@ -48,9 +48,7 @@ export class RequestTime {
|
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
/**
|
|
51
|
-
* Creates a new
|
|
52
|
-
*
|
|
53
|
-
* Note, this throws an error when the server is not an ARC thing.
|
|
51
|
+
* Creates a new timing clearing anything that is so far defined.
|
|
54
52
|
*/
|
|
55
53
|
new(init: IRequestTime): void {
|
|
56
54
|
const { connect=-1, receive=-1, send=-1, wait=-1, blocked=-1, dns=-1, ssl=-1 } = init;
|
|
@@ -2,7 +2,7 @@ import { IProperty, Property } from './Property.js';
|
|
|
2
2
|
import { IMultipartBody } from '../lib/transformers/PayloadSerializer.js';
|
|
3
3
|
import { RequestUiMeta as LegacyRequestUiMeta } from './legacy/request/ArcRequest.js';
|
|
4
4
|
|
|
5
|
-
export const Kind = '
|
|
5
|
+
export const Kind = 'Core#RequestUiMeta';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* URL editor meta data.
|
|
@@ -41,7 +41,7 @@ export interface IAuthMeta {
|
|
|
41
41
|
|
|
42
42
|
export interface IActionsMeta {
|
|
43
43
|
/**
|
|
44
|
-
* The index of the selected
|
|
44
|
+
* The index of the selected API Client actions view.
|
|
45
45
|
*/
|
|
46
46
|
selected?: number;
|
|
47
47
|
}
|
|
@@ -64,7 +64,7 @@ export interface IResponseUiMeta {
|
|
|
64
64
|
*/
|
|
65
65
|
export interface IBodyMetaModel {
|
|
66
66
|
/**
|
|
67
|
-
* The id of the editor. Each editor in
|
|
67
|
+
* The id of the editor. Each editor in API Client has own id.
|
|
68
68
|
*/
|
|
69
69
|
type: string;
|
|
70
70
|
/**
|
|
@@ -124,7 +124,7 @@ export interface IRequestUiMeta {
|
|
|
124
124
|
*/
|
|
125
125
|
authorization?: IAuthMeta;
|
|
126
126
|
/**
|
|
127
|
-
*
|
|
127
|
+
* API Client request actions editor UI config.
|
|
128
128
|
*/
|
|
129
129
|
actions?: IActionsMeta;
|
|
130
130
|
/**
|
|
@@ -156,7 +156,7 @@ export class RequestUiMeta {
|
|
|
156
156
|
*/
|
|
157
157
|
authorization?: IAuthMeta;
|
|
158
158
|
/**
|
|
159
|
-
*
|
|
159
|
+
* API Client request actions editor UI config.
|
|
160
160
|
*/
|
|
161
161
|
actions?: IActionsMeta;
|
|
162
162
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export const Kind = '
|
|
1
|
+
export const Kind = 'Core#ResponseSize';
|
|
2
2
|
|
|
3
3
|
export interface IRequestsSize {
|
|
4
4
|
kind?: typeof Kind;
|
|
@@ -44,8 +44,6 @@ export class RequestsSize {
|
|
|
44
44
|
|
|
45
45
|
/**
|
|
46
46
|
* Creates a new response size clearing anything that is so far defined.
|
|
47
|
-
*
|
|
48
|
-
* Note, this throws an error when the object is not an ARC response size.
|
|
49
47
|
*/
|
|
50
48
|
new(init: IRequestsSize): void {
|
|
51
49
|
const { request, response } = init;
|
|
@@ -11,7 +11,7 @@ export { Kind };
|
|
|
11
11
|
/**
|
|
12
12
|
* An HTTP response object.
|
|
13
13
|
*/
|
|
14
|
-
export interface
|
|
14
|
+
export interface IResponse extends IHttpResponse {
|
|
15
15
|
/**
|
|
16
16
|
* The request timings.
|
|
17
17
|
* Some HTTP clients may not give this information.
|
|
@@ -27,7 +27,7 @@ export interface IArcResponse extends IHttpResponse {
|
|
|
27
27
|
auth?: IResponseAuthorization;
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
-
export class
|
|
30
|
+
export class Response extends HttpResponse {
|
|
31
31
|
/**
|
|
32
32
|
* The request timings.
|
|
33
33
|
* Some HTTP clients may not give this information.
|
|
@@ -42,8 +42,8 @@ export class ArcResponse extends HttpResponse {
|
|
|
42
42
|
*/
|
|
43
43
|
auth?: ResponseAuthorization;
|
|
44
44
|
|
|
45
|
-
static fromValues(status: number, statusText?: string, headers?: string):
|
|
46
|
-
return new
|
|
45
|
+
static fromValues(status: number, statusText?: string, headers?: string): Response {
|
|
46
|
+
return new Response({
|
|
47
47
|
kind: Kind,
|
|
48
48
|
status,
|
|
49
49
|
statusText,
|
|
@@ -52,8 +52,8 @@ export class ArcResponse extends HttpResponse {
|
|
|
52
52
|
});
|
|
53
53
|
}
|
|
54
54
|
|
|
55
|
-
static async fromLegacy(input: LegacyResponse): Promise<
|
|
56
|
-
const init:
|
|
55
|
+
static async fromLegacy(input: LegacyResponse): Promise<Response> {
|
|
56
|
+
const init: IResponse = {
|
|
57
57
|
kind: Kind,
|
|
58
58
|
status: input.status || 0,
|
|
59
59
|
loadingTime: input.loadingTime || 0,
|
|
@@ -83,15 +83,15 @@ export class ArcResponse extends HttpResponse {
|
|
|
83
83
|
if (input.timings) {
|
|
84
84
|
init.timings = new RequestTime(input.timings).toJSON();
|
|
85
85
|
}
|
|
86
|
-
return new
|
|
86
|
+
return new Response(init);
|
|
87
87
|
}
|
|
88
88
|
|
|
89
89
|
/**
|
|
90
90
|
* @param input The response definition used to restore the state.
|
|
91
91
|
*/
|
|
92
|
-
constructor(input?: string|
|
|
92
|
+
constructor(input?: string|IResponse) {
|
|
93
93
|
super();
|
|
94
|
-
let init:
|
|
94
|
+
let init: IResponse;
|
|
95
95
|
if (typeof input === 'string') {
|
|
96
96
|
init = JSON.parse(input);
|
|
97
97
|
} else if (typeof input === 'object') {
|
|
@@ -108,10 +108,8 @@ export class ArcResponse extends HttpResponse {
|
|
|
108
108
|
|
|
109
109
|
/**
|
|
110
110
|
* Creates a new response clearing anything that is so far defined.
|
|
111
|
-
*
|
|
112
|
-
* Note, this throws an error when the object is not an ARC response.
|
|
113
111
|
*/
|
|
114
|
-
new(init:
|
|
112
|
+
new(init: IResponse): void {
|
|
115
113
|
super.new(init);
|
|
116
114
|
const { loadingTime=0, timings, auth } = init;
|
|
117
115
|
this.loadingTime = loadingTime;
|
|
@@ -127,8 +125,8 @@ export class ArcResponse extends HttpResponse {
|
|
|
127
125
|
}
|
|
128
126
|
}
|
|
129
127
|
|
|
130
|
-
toJSON():
|
|
131
|
-
const response = super.toJSON() as
|
|
128
|
+
toJSON(): IResponse {
|
|
129
|
+
const response = super.toJSON() as IResponse;
|
|
132
130
|
response.loadingTime = this.loadingTime;
|
|
133
131
|
if (this.timings) {
|
|
134
132
|
response.timings = this.timings.toJSON();
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export const Kind = '
|
|
1
|
+
export const Kind = 'Core#ResponseAuthorization';
|
|
2
2
|
|
|
3
3
|
export interface IResponseAuthorization {
|
|
4
|
-
kind:
|
|
4
|
+
kind: typeof Kind;
|
|
5
5
|
/**
|
|
6
6
|
* The requested by the authorization server authentication method
|
|
7
7
|
*/
|
|
@@ -60,11 +60,11 @@ export class ResponseAuthorization {
|
|
|
60
60
|
/**
|
|
61
61
|
* Creates a new response authorization clearing anything that is so far defined.
|
|
62
62
|
*
|
|
63
|
-
* Note, this throws an error when the object is not
|
|
63
|
+
* Note, this throws an error when the object is not a response authorization.
|
|
64
64
|
*/
|
|
65
65
|
new(init: IResponseAuthorization): void {
|
|
66
66
|
if (!ResponseAuthorization.isResponseAuthorization(init)) {
|
|
67
|
-
throw new Error(`Not
|
|
67
|
+
throw new Error(`Not a response authorization.`);
|
|
68
68
|
}
|
|
69
69
|
const { method, state, headers, challengeHeader } = init;
|
|
70
70
|
this.kind = Kind;
|
|
@@ -2,13 +2,13 @@ import { IHttpResponse, HttpResponse, Kind as ResponseKind } from './HttpRespons
|
|
|
2
2
|
import { IRequestTime, RequestTime } from './RequestTime.js';
|
|
3
3
|
import { ResponseRedirect as LegacyRedirect } from './legacy/request/ArcResponse.js';
|
|
4
4
|
|
|
5
|
-
export const Kind = '
|
|
5
|
+
export const Kind = 'Core#HttpResponseRedirect';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* An information about a redirect
|
|
9
9
|
*/
|
|
10
10
|
export interface IResponseRedirect {
|
|
11
|
-
kind:
|
|
11
|
+
kind: typeof Kind;
|
|
12
12
|
/**
|
|
13
13
|
* Redirection response
|
|
14
14
|
*/
|
|
@@ -33,7 +33,7 @@ export interface IResponseRedirect {
|
|
|
33
33
|
|
|
34
34
|
|
|
35
35
|
export class ResponseRedirect {
|
|
36
|
-
kind = Kind;
|
|
36
|
+
kind: typeof Kind = Kind;
|
|
37
37
|
/**
|
|
38
38
|
* Redirection response
|
|
39
39
|
*/
|
|
@@ -119,8 +119,6 @@ export class ResponseRedirect {
|
|
|
119
119
|
|
|
120
120
|
/**
|
|
121
121
|
* Creates a new redirect clearing anything that is so far defined.
|
|
122
|
-
*
|
|
123
|
-
* Note, this throws an error when the object is not an ARC redirect.
|
|
124
122
|
*/
|
|
125
123
|
new(init: IResponseRedirect): void {
|
|
126
124
|
const { response, timings, startTime=0, endTime=0, url='', kind=Kind } = init;
|
|
@@ -21,7 +21,7 @@ export interface IBaseSentRequest extends IBaseHttpRequest {
|
|
|
21
21
|
|
|
22
22
|
/**
|
|
23
23
|
* An interface describing a request made by the HTTP transport.
|
|
24
|
-
* Each transport used by
|
|
24
|
+
* Each transport used by API Client must return this structure in the response event.
|
|
25
25
|
* This is not a replacement for the editor request that also has to be returned.
|
|
26
26
|
*
|
|
27
27
|
* Another difference is that this headers contains a final list of headers sent to the
|
|
@@ -103,9 +103,7 @@ export class SentRequest extends HttpRequest {
|
|
|
103
103
|
}
|
|
104
104
|
|
|
105
105
|
/**
|
|
106
|
-
* Creates a new request clearing anything that is so far defined.
|
|
107
|
-
*
|
|
108
|
-
* Note, this throws an error when the object is not an ARC request.
|
|
106
|
+
* Creates a new sent request clearing anything that is so far defined.
|
|
109
107
|
*/
|
|
110
108
|
new(init: ISentRequest): void {
|
|
111
109
|
super.new(init);
|
package/src/models/Server.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export const Kind = '
|
|
1
|
+
export const Kind = 'Core#Server';
|
|
2
2
|
|
|
3
3
|
export interface IServer {
|
|
4
|
-
kind:
|
|
4
|
+
kind: typeof Kind;
|
|
5
5
|
/**
|
|
6
6
|
* The base URI of the server.
|
|
7
7
|
*
|
|
@@ -85,11 +85,11 @@ export class Server {
|
|
|
85
85
|
/**
|
|
86
86
|
* Creates a new server clearing anything that is so far defined.
|
|
87
87
|
*
|
|
88
|
-
* Note, this throws an error when the server is not
|
|
88
|
+
* Note, this throws an error when the server is not a server.
|
|
89
89
|
*/
|
|
90
90
|
new(init: IServer): void {
|
|
91
91
|
if (!Server.isServer(init)) {
|
|
92
|
-
throw new Error(`Not
|
|
92
|
+
throw new Error(`Not a server.`);
|
|
93
93
|
}
|
|
94
94
|
const { uri, description, protocol, basePath } = init;
|
|
95
95
|
this.kind = Kind;
|
package/src/models/Thing.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export const Kind = '
|
|
1
|
+
export const Kind = 'Core#Thing';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* An interface describing a base metadata of a thing.
|
|
@@ -7,7 +7,7 @@ export declare interface IThing {
|
|
|
7
7
|
/**
|
|
8
8
|
* The data kind. The application ignores the input with an unknown `kind`, unless it can be determined from the context.
|
|
9
9
|
*/
|
|
10
|
-
kind?:
|
|
10
|
+
kind?: typeof Kind;
|
|
11
11
|
/**
|
|
12
12
|
* The name of the thing.
|
|
13
13
|
*/
|
|
@@ -68,11 +68,11 @@ export class Thing {
|
|
|
68
68
|
/**
|
|
69
69
|
* Creates a new thing clearing anything that is so far defined.
|
|
70
70
|
*
|
|
71
|
-
* Note, this throws an error when the server is not
|
|
71
|
+
* Note, this throws an error when the server is not a thing.
|
|
72
72
|
*/
|
|
73
73
|
new(init: IThing): void {
|
|
74
74
|
if (!Thing.isThing(init)) {
|
|
75
|
-
throw new Error(`Not
|
|
75
|
+
throw new Error(`Not a thing.`);
|
|
76
76
|
}
|
|
77
77
|
const { description, name, version } = init;
|
|
78
78
|
this.kind = Kind;
|
package/src/models/Url.ts
CHANGED
|
@@ -41,7 +41,7 @@ export class Url {
|
|
|
41
41
|
midnight?: number;
|
|
42
42
|
|
|
43
43
|
/**
|
|
44
|
-
* @param input The
|
|
44
|
+
* @param input The URL definition used to restore the state.
|
|
45
45
|
*/
|
|
46
46
|
constructor(input: string|IUrl) {
|
|
47
47
|
let init: IUrl;
|
|
@@ -60,9 +60,7 @@ export class Url {
|
|
|
60
60
|
}
|
|
61
61
|
|
|
62
62
|
/**
|
|
63
|
-
* Creates a new
|
|
64
|
-
*
|
|
65
|
-
* Note, this throws an error when the environment is not an ARC environment.
|
|
63
|
+
* Creates a new URL clearing anything that is so far defined.
|
|
66
64
|
*/
|
|
67
65
|
new(init: IUrl): void {
|
|
68
66
|
const { url='', cnt=0, time = Date.now(), midnight } = init;
|
package/src/models/User.ts
CHANGED
package/src/models/WebApi.ts
CHANGED
package/src/models/Workspace.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { AccessControlLevel } from "./User.js";
|
|
|
2
2
|
import { IThing, Thing, Kind as ThingKind } from './Thing.js';
|
|
3
3
|
import v4 from '../lib/uuid.js';
|
|
4
4
|
|
|
5
|
-
export const Kind = '
|
|
5
|
+
export const Kind = 'Core#Space';
|
|
6
6
|
/**
|
|
7
7
|
* A definition of the working space for users.
|
|
8
8
|
*
|
|
@@ -10,7 +10,7 @@ export const Kind = 'ARC#Space';
|
|
|
10
10
|
* created by the system users, where they can store their projects and other data.
|
|
11
11
|
*/
|
|
12
12
|
export interface IWorkspace {
|
|
13
|
-
kind:
|
|
13
|
+
kind: typeof Kind;
|
|
14
14
|
/**
|
|
15
15
|
* The space identifier.
|
|
16
16
|
*/
|
|
@@ -75,7 +75,7 @@ export class Workspace {
|
|
|
75
75
|
*/
|
|
76
76
|
projects: string[] = [];
|
|
77
77
|
/**
|
|
78
|
-
* Only set when the object was created from the data received by the
|
|
78
|
+
* Only set when the object was created from the data received by the API Client backend.
|
|
79
79
|
* Level access of the current user to the space.
|
|
80
80
|
* Note, this information is never serialized with the object.
|
|
81
81
|
*/
|
|
@@ -127,11 +127,11 @@ export class Workspace {
|
|
|
127
127
|
/**
|
|
128
128
|
* Creates a new environment clearing anything that is so far defined.
|
|
129
129
|
*
|
|
130
|
-
* Note, this throws an error when the environment is not
|
|
130
|
+
* Note, this throws an error when the environment is not a space.
|
|
131
131
|
*/
|
|
132
132
|
new(init: IWorkspace | IUserWorkspace): void {
|
|
133
133
|
if (!Workspace.isWorkspace(init)) {
|
|
134
|
-
throw new Error(`Not
|
|
134
|
+
throw new Error(`Not a space.`);
|
|
135
135
|
}
|
|
136
136
|
const { key = v4(), projects = [], info, owner = DefaultOwner, users } = init;
|
|
137
137
|
this.kind = Kind;
|
|
@@ -5,13 +5,13 @@ import { Kind as SetCookieKind, SetCookieAction, ISetCookieAction } from './runn
|
|
|
5
5
|
import { Kind as SetVariableKind, SetVariableAction, ISetVariableAction } from './runnable/SetVariableAction.js';
|
|
6
6
|
import { Action as LegacyAction, SetCookieConfig, SetVariableConfig, DeleteCookieConfig } from '../legacy/actions/Actions.js';
|
|
7
7
|
|
|
8
|
-
export const Kind = '
|
|
8
|
+
export const Kind = 'Core#Action';
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
11
|
* An interface representing a single action.
|
|
12
12
|
*/
|
|
13
13
|
export interface IAction {
|
|
14
|
-
kind?:
|
|
14
|
+
kind?: typeof Kind;
|
|
15
15
|
/**
|
|
16
16
|
* Action name.
|
|
17
17
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ActionTypeEnum, RequestDataSourceEnum, ResponseDataSourceEnum, OperatorEnum } from './Enums.js';
|
|
2
2
|
import { Condition as LegacyCondition } from '../legacy/actions/Actions.js';
|
|
3
3
|
|
|
4
|
-
export const Kind = '
|
|
4
|
+
export const Kind = 'Core#Condition';
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* A base interface describing a configuration to extract data from a request or a response.
|
|
@@ -33,7 +33,7 @@ export interface IDataSource {
|
|
|
33
33
|
* Describes action's condition configuration.
|
|
34
34
|
*/
|
|
35
35
|
export interface ICondition extends IDataSource {
|
|
36
|
-
kind:
|
|
36
|
+
kind: typeof Kind,
|
|
37
37
|
/**
|
|
38
38
|
* The comparison operator.
|
|
39
39
|
*/
|
|
@@ -2,7 +2,7 @@ import { ICondition, Condition } from './Condition.js';
|
|
|
2
2
|
import { IAction, Action } from './Action.js';
|
|
3
3
|
import { RunnableAction as LegacyRunnable } from '../legacy/actions/Actions.js';
|
|
4
4
|
|
|
5
|
-
export const Kind = '
|
|
5
|
+
export const Kind = 'Core#RunnableAction';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* An interface representing a runnable set of action in a condition.
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { DeleteCookieConfig } from '../../legacy/actions/Actions.js';
|
|
2
2
|
import { Runnable, IRunnable } from './Runnable.js';
|
|
3
3
|
|
|
4
|
-
export const Kind = '
|
|
4
|
+
export const Kind = 'Core#DeleteCookieAction';
|
|
5
5
|
|
|
6
6
|
export interface IDeleteCookieAction extends IRunnable {
|
|
7
|
-
kind?:
|
|
7
|
+
kind?: typeof Kind;
|
|
8
8
|
/**
|
|
9
9
|
* When set it uses request URL instead of defined URL in the action.
|
|
10
10
|
*/
|
|
@@ -3,10 +3,10 @@ import { Runnable, IRunnable } from './Runnable.js';
|
|
|
3
3
|
import { IDataSource } from '../Condition.js';
|
|
4
4
|
import { RequestDataSourceEnum } from '../Enums.js';
|
|
5
5
|
|
|
6
|
-
export const Kind = '
|
|
6
|
+
export const Kind = 'Core#SetCookieAction';
|
|
7
7
|
|
|
8
8
|
export interface ISetCookieAction extends IRunnable {
|
|
9
|
-
kind?:
|
|
9
|
+
kind?: typeof Kind;
|
|
10
10
|
/**
|
|
11
11
|
* Name of the cookie
|
|
12
12
|
*/
|
|
@@ -3,10 +3,10 @@ import { Runnable, IRunnable } from './Runnable.js';
|
|
|
3
3
|
import { IDataSource } from '../Condition.js';
|
|
4
4
|
import { RequestDataSourceEnum } from '../Enums.js';
|
|
5
5
|
|
|
6
|
-
export const Kind = '
|
|
6
|
+
export const Kind = 'Core#SetVariableAction';
|
|
7
7
|
|
|
8
8
|
export interface ISetVariableAction extends IRunnable {
|
|
9
|
-
kind?:
|
|
9
|
+
kind?: typeof Kind;
|
|
10
10
|
/**
|
|
11
11
|
* Name of the variable to set
|
|
12
12
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/* eslint-disable no-param-reassign */
|
|
2
2
|
/* eslint-disable no-plusplus */
|
|
3
3
|
/**
|
|
4
|
-
* User can export single request in ARC. In this case
|
|
4
|
+
* User can export single request in ARC. In this case the app opens new tab
|
|
5
5
|
* rather actually imports the data. This function tests if this is the case.
|
|
6
6
|
* @param data Normalized import data
|
|
7
7
|
*/
|
|
@@ -5,6 +5,7 @@ import { ProjectFolder } from '../ProjectFolder.js';
|
|
|
5
5
|
import { ProjectRequest } from '../ProjectRequest.js';
|
|
6
6
|
import { IMultipartBody } from '../../lib/transformers/PayloadSerializer.js';
|
|
7
7
|
import { Environment } from '../Environment.js';
|
|
8
|
+
import { Kind as ThingKind } from '../Thing.js';
|
|
8
9
|
|
|
9
10
|
interface PostmanBackupV1 {
|
|
10
11
|
version: number;
|
|
@@ -147,7 +148,7 @@ export class PostmanBackupTransformer extends PostmanTransformer {
|
|
|
147
148
|
definitions: {},
|
|
148
149
|
environments: [],
|
|
149
150
|
info: {
|
|
150
|
-
kind:
|
|
151
|
+
kind: ThingKind,
|
|
151
152
|
name,
|
|
152
153
|
},
|
|
153
154
|
items: [],
|
|
@@ -6,6 +6,7 @@ import { ProjectRequest } from '../ProjectRequest.js';
|
|
|
6
6
|
import { IMultipartBody } from '../../lib/transformers/PayloadSerializer.js';
|
|
7
7
|
import v4 from '../../lib/uuid.js';
|
|
8
8
|
import { Environment } from '../Environment.js';
|
|
9
|
+
import { Kind as ThingKind } from '../Thing.js';
|
|
9
10
|
|
|
10
11
|
export const currentItemValue = Symbol('currentItemValue');
|
|
11
12
|
|
|
@@ -134,7 +135,7 @@ export class PostmanV21Transformer extends PostmanTransformer {
|
|
|
134
135
|
definitions: {},
|
|
135
136
|
environments: [],
|
|
136
137
|
info: {
|
|
137
|
-
kind:
|
|
138
|
+
kind: ThingKind,
|
|
138
139
|
name: info.name || 'Unnamed Postman project',
|
|
139
140
|
},
|
|
140
141
|
items: [],
|
|
@@ -6,6 +6,7 @@ import { ProjectRequest } from '../ProjectRequest.js';
|
|
|
6
6
|
import { IMultipartBody } from '../../lib/transformers/PayloadSerializer.js';
|
|
7
7
|
import v4 from '../../lib/uuid.js';
|
|
8
8
|
import { Environment } from '../Environment.js';
|
|
9
|
+
import { Kind as ThingKind } from '../Thing.js';
|
|
9
10
|
|
|
10
11
|
export const currentItemValue = Symbol('currentItemValue');
|
|
11
12
|
|
|
@@ -131,7 +132,7 @@ export class PostmanV2Transformer extends PostmanTransformer {
|
|
|
131
132
|
definitions: {},
|
|
132
133
|
environments: [],
|
|
133
134
|
info: {
|
|
134
|
-
kind:
|
|
135
|
+
kind: ThingKind,
|
|
135
136
|
name: info.name || 'Unnamed Postman project',
|
|
136
137
|
},
|
|
137
138
|
items: [],
|