From 9f6284c696701b9f1668c2849693a81fda85137d Mon Sep 17 00:00:00 2001 From: github-actions Date: Mon, 8 Jan 2024 15:18:27 +0000 Subject: [PATCH] Updating from 8615da434deabe2dab1f694719f0b67a384cb8ac --- assets/highlight.css | 92 ++ assets/main.js | 59 + assets/navigation.js | 1 + assets/search.js | 1 + assets/style.css | 1394 +++++++++++++++++ functions/runFromAPI.html | 4 + index.html | 51 + index.md | 12 - interfaces/APIOptions.html | 14 + interfaces/CLIConfigurationSpec.html | 106 ++ interfaces/ChecksumArgs.html | 33 + interfaces/ConfigurationSpec.html | 138 ++ interfaces/Connection.html | 8 + interfaces/ConsoleSpec.html | 8 + interfaces/FilterableSpec.html | 12 + interfaces/GetConfigurationProps.html | 12 + interfaces/HarFormatContent.html | 17 + interfaces/HarFormatEntry.html | 35 + interfaces/HarFormatNameValuePair.html | 8 + interfaces/HarFormatPostData.html | 13 + interfaces/HarFormatRequest.html | 26 + interfaces/HarFormatResponse.html | 23 + interfaces/HarFormatTimings.html | 23 + interfaces/HookAPI.html | 8 + interfaces/IConfigurationFile.html | 6 + interfaces/IConfigurationProperty.html | 6 + interfaces/IFetchedRequest.html | 26 + interfaces/IMock.html | 226 +++ interfaces/IProxyConnectAPI.html | 37 + interfaces/IResponse.html | 28 + interfaces/IncludableSpec.html | 5 + interfaces/MockData.html | 22 + interfaces/MockingOptions.html | 7 + interfaces/Payload.html | 9 + interfaces/PayloadWithOrigin.html | 6 + interfaces/RemotePayload.html | 8 + interfaces/RequestPayload.html | 10 + interfaces/RequestTimings.html | 21 + interfaces/Status.html | 6 + kassette.apioptions.apiconfiguration.md | 18 - kassette.apioptions.configurationpath.md | 13 - ...tte.apioptions.fileconfigurationcontext.md | 13 - kassette.apioptions.md | 22 - kassette.checksumargs.body.md | 13 - kassette.checksumargs.customdata.md | 13 - kassette.checksumargs.format.md | 13 - kassette.checksumargs.headers.md | 13 - kassette.checksumargs.hostname.md | 13 - kassette.checksumargs.md | 34 - kassette.checksumargs.method.md | 13 - kassette.checksumargs.pathname.md | 13 - kassette.checksumargs.port.md | 13 - kassette.checksumargs.protocol.md | 13 - kassette.checksumargs.query.md | 13 - kassette.checksumargs.type.md | 13 - kassette.cliconfigurationspec.delay.md | 18 - ...e.cliconfigurationspec.harfilecachetime.md | 13 - kassette.cliconfigurationspec.hostname.md | 18 - kassette.cliconfigurationspec.http2.md | 13 - kassette.cliconfigurationspec.md | 39 - kassette.cliconfigurationspec.mocksfolder.md | 18 - kassette.cliconfigurationspec.mocksformat.md | 20 - kassette.cliconfigurationspec.mocksharfile.md | 18 - kassette.cliconfigurationspec.mode.md | 18 - kassette.cliconfigurationspec.port.md | 18 - ...e.cliconfigurationspec.proxyconnectmode.md | 18 - kassette.cliconfigurationspec.remoteurl.md | 18 - ...liconfigurationspec.savechecksumcontent.md | 20 - ...liconfigurationspec.savedetailedtimings.md | 20 - ...figurationspec.saveforwardedrequestbody.md | 20 - ...figurationspec.saveforwardedrequestdata.md | 20 - ...iconfigurationspec.saveinputrequestbody.md | 20 - ...iconfigurationspec.saveinputrequestdata.md | 20 - kassette.cliconfigurationspec.skiplog.md | 13 - kassette.cliconfigurationspec.tlscakeypath.md | 18 - kassette.cliconfigurationspec.tlskeysize.md | 13 - kassette.configurationpropertysource.md | 13 - kassette.configurationspec.console.md | 13 - ...configurationspec.harmimetypesparsejson.md | 13 - kassette.configurationspec.hook.md | 24 - kassette.configurationspec.md | 32 - ...te.configurationspec.mocksharkeymanager.md | 18 - kassette.configurationspec.onexit.md | 17 - kassette.configurationspec.onlisten.md | 26 - kassette.configurationspec.onproxyconnect.md | 24 - kassette.connection.hostname.md | 13 - kassette.connection.md | 22 - kassette.connection.port.md | 13 - kassette.connection.protocol.md | 13 - kassette.consolespec.error.md | 24 - kassette.consolespec.log.md | 24 - kassette.consolespec.md | 21 - kassette.delay.md | 18 - kassette.filterablespec.filter.md | 26 - kassette.filterablespec.md | 21 - ....getconfigurationprops.apiconfiguration.md | 13 - ....getconfigurationprops.cliconfiguration.md | 13 - kassette.getconfigurationprops.context.md | 13 - kassette.getconfigurationprops.md | 22 - kassette.harformatcontent.comment.md | 13 - kassette.harformatcontent.compression.md | 13 - kassette.harformatcontent.encoding.md | 13 - kassette.harformatcontent.json.md | 13 - kassette.harformatcontent.md | 26 - kassette.harformatcontent.mimetype.md | 13 - kassette.harformatcontent.size.md | 13 - kassette.harformatcontent.text.md | 18 - ...harformatentry._kassettechecksumcontent.md | 18 - ...arformatentry._kassetteforwardedrequest.md | 18 - kassette.harformatentry._kassettemockkey.md | 18 - kassette.harformatentry.cache.md | 13 - kassette.harformatentry.comment.md | 13 - kassette.harformatentry.connection.md | 13 - kassette.harformatentry.md | 32 - kassette.harformatentry.pageref.md | 13 - kassette.harformatentry.request.md | 18 - kassette.harformatentry.response.md | 13 - kassette.harformatentry.serveripaddress.md | 13 - kassette.harformatentry.starteddatetime.md | 13 - kassette.harformatentry.time.md | 13 - kassette.harformatentry.timings.md | 18 - kassette.harformatnamevaluepair.comment.md | 13 - kassette.harformatnamevaluepair.md | 22 - kassette.harformatnamevaluepair.name.md | 13 - kassette.harformatnamevaluepair.value.md | 13 - kassette.harformatpostdata.comment.md | 13 - kassette.harformatpostdata.json.md | 13 - kassette.harformatpostdata.md | 24 - kassette.harformatpostdata.mimetype.md | 13 - kassette.harformatpostdata.params.md | 18 - kassette.harformatpostdata.text.md | 13 - kassette.harformatrequest.bodysize.md | 13 - kassette.harformatrequest.comment.md | 13 - kassette.harformatrequest.cookies.md | 13 - kassette.harformatrequest.headers.md | 13 - kassette.harformatrequest.headerssize.md | 13 - kassette.harformatrequest.httpversion.md | 13 - kassette.harformatrequest.md | 29 - kassette.harformatrequest.method.md | 13 - kassette.harformatrequest.postdata.md | 18 - kassette.harformatrequest.querystring.md | 13 - kassette.harformatrequest.url.md | 13 - kassette.harformatresponse.bodysize.md | 13 - kassette.harformatresponse.comment.md | 13 - kassette.harformatresponse.content.md | 13 - kassette.harformatresponse.cookies.md | 13 - kassette.harformatresponse.headers.md | 13 - kassette.harformatresponse.headerssize.md | 13 - kassette.harformatresponse.httpversion.md | 13 - kassette.harformatresponse.md | 29 - kassette.harformatresponse.redirecturl.md | 13 - kassette.harformatresponse.status.md | 13 - kassette.harformatresponse.statustext.md | 13 - kassette.harformattimings.comment.md | 13 - kassette.harformattimings.md | 21 - kassette.harkeymanager.md | 44 - kassette.headers_2.md | 13 - kassette.hookapi.console.md | 13 - kassette.hookapi.md | 21 - kassette.hookapi.mock.md | 13 - ...tte.iconfigurationfile.getconfiguration.md | 24 - kassette.iconfigurationfile.md | 20 - kassette.iconfigurationproperty.md | 21 - kassette.iconfigurationproperty.origin.md | 13 - kassette.iconfigurationproperty.value.md | 13 - kassette.ifetchedrequest.body.md | 13 - kassette.ifetchedrequest.connection.md | 13 - kassette.ifetchedrequest.connectionsstack.md | 13 - kassette.ifetchedrequest.headers.md | 13 - kassette.ifetchedrequest.hostname.md | 13 - kassette.ifetchedrequest.md | 31 - kassette.ifetchedrequest.method.md | 13 - kassette.ifetchedrequest.original.md | 13 - kassette.ifetchedrequest.pathname.md | 13 - kassette.ifetchedrequest.port.md | 13 - kassette.ifetchedrequest.protocol.md | 13 - kassette.ifetchedrequest.queryparameters.md | 13 - kassette.ifetchedrequest.url.md | 13 - kassette.imergedconfiguration.md | 23 - kassette.imock.checksum.md | 36 - kassette.imock.checksumcontent.md | 13 - kassette.imock.createpayload.md | 24 - kassette.imock.defaultlocalpath.md | 13 - kassette.imock.defaultmockharkey.md | 18 - kassette.imock.delay.md | 13 - kassette.imock.downloadpayload.md | 17 - kassette.imock.fetchpayload.md | 17 - kassette.imock.fillresponsefrompayload.md | 28 - kassette.imock.getpayloadandfillresponse.md | 17 - kassette.imock.harmimetypesparsejson.md | 13 - kassette.imock.haslocalfiles.md | 26 - kassette.imock.haslocalmock.md | 21 - kassette.imock.hasnolocalfiles.md | 26 - kassette.imock.hasnolocalmock.md | 21 - kassette.imock.localpath.md | 13 - kassette.imock.md | 84 - kassette.imock.mockfolderfullpath.md | 13 - kassette.imock.mockharkey.md | 18 - kassette.imock.mocksfolder.md | 13 - kassette.imock.mocksformat.md | 13 - kassette.imock.mocksharfile.md | 13 - kassette.imock.mocksharkeymanager.md | 13 - kassette.imock.mode.md | 13 - kassette.imock.options.md | 13 - kassette.imock.persistpayload.md | 24 - kassette.imock.process.md | 21 - kassette.imock.readlocalpayload.md | 17 - ...e.imock.readlocalpayloadandfillresponse.md | 17 - kassette.imock.readordownloadpayload.md | 17 - kassette.imock.readorfetchpayload.md | 17 - kassette.imock.remoteurl.md | 13 - kassette.imock.request.md | 13 - kassette.imock.response.md | 13 - kassette.imock.savechecksumcontent.md | 13 - kassette.imock.savedetailedtimings.md | 13 - kassette.imock.saveforwardedrequestbody.md | 13 - kassette.imock.saveforwardedrequestdata.md | 13 - kassette.imock.saveinputrequestbody.md | 13 - kassette.imock.saveinputrequestdata.md | 13 - kassette.imock.sendresponse.md | 17 - kassette.imock.setdelay.md | 24 - kassette.imock.setharmimetypesparsejson.md | 24 - kassette.imock.setlocalpath.md | 40 - kassette.imock.setmockharkey.md | 24 - kassette.imock.setmocksfolder.md | 24 - kassette.imock.setmocksformat.md | 24 - kassette.imock.setmocksharfile.md | 24 - kassette.imock.setmocksharkeymanager.md | 24 - kassette.imock.setmode.md | 24 - kassette.imock.setpayload.md | 24 - kassette.imock.setremoteurl.md | 24 - kassette.imock.setsavechecksumcontent.md | 24 - kassette.imock.setsavedetailedtimings.md | 24 - kassette.imock.setsaveforwardedrequestbody.md | 24 - kassette.imock.setsaveforwardedrequestdata.md | 24 - kassette.imock.setsaveinputrequestbody.md | 24 - kassette.imock.setsaveinputrequestdata.md | 24 - kassette.imock.sourcepayload.md | 13 - kassette.includablespec.include.md | 13 - kassette.includablespec.md | 20 - kassette.iproxyconnectapi.connection.md | 13 - kassette.iproxyconnectapi.connectionsstack.md | 13 - ...te.iproxyconnectapi.destinationhostname.md | 13 - kassette.iproxyconnectapi.destinationport.md | 13 - kassette.iproxyconnectapi.hostname.md | 13 - kassette.iproxyconnectapi.md | 36 - kassette.iproxyconnectapi.mode.md | 13 - kassette.iproxyconnectapi.port.md | 13 - kassette.iproxyconnectapi.process.md | 17 - kassette.iproxyconnectapi.request.md | 13 - kassette.iproxyconnectapi.setdestination.md | 25 - kassette.iproxyconnectapi.setmode.md | 24 - kassette.iproxyconnectapi.socket.md | 13 - kassette.iresponse.body.md | 18 - kassette.iresponse.headers.md | 13 - kassette.iresponse.json.md | 18 - kassette.iresponse.md | 32 - kassette.iresponse.original.md | 13 - kassette.iresponse.send.md | 17 - kassette.iresponse.setdata.md | 24 - kassette.iresponse.setheaders.md | 24 - kassette.iresponse.status.md | 13 - kassette.listorfilter.md | 34 - kassette.md | 66 - kassette.mockdata.bodyfilename.md | 13 - kassette.mockdata.creationdatetime.md | 13 - kassette.mockdata.headers.md | 13 - kassette.mockdata.httpversion.md | 13 - kassette.mockdata.ignoredheaders.md | 13 - kassette.mockdata.md | 27 - kassette.mockdata.status.md | 13 - kassette.mockdata.time.md | 13 - kassette.mockdata.timings.md | 13 - kassette.mockingoptions.md | 21 - kassette.mockingoptions.root.md | 13 - kassette.mockingoptions.userconfiguration.md | 13 - kassette.mocksformat.md | 22 - kassette.mode.md | 30 - kassette.payload.body.md | 13 - kassette.payload.data.md | 13 - kassette.payload.md | 29 - kassette.payloadorigin.md | 26 - kassette.payloadwithorigin.md | 21 - kassette.payloadwithorigin.origin.md | 13 - kassette.payloadwithorigin.payload.md | 13 - kassette.proxyconnectmode.md | 26 - kassette.recursivearray.md | 15 - kassette.remotepayload.md | 21 - kassette.remotepayload.requestoptions.md | 13 - kassette.requestpayload.body.md | 13 - kassette.requestpayload.headers.md | 13 - kassette.requestpayload.md | 23 - kassette.requestpayload.method.md | 13 - kassette.requestpayload.url.md | 13 - kassette.requesttimings.blocked.md | 13 - kassette.requesttimings.connect.md | 13 - kassette.requesttimings.dns.md | 13 - kassette.requesttimings.md | 26 - kassette.requesttimings.receive.md | 13 - kassette.requesttimings.send.md | 13 - kassette.requesttimings.ssl.md | 13 - kassette.requesttimings.wait.md | 13 - kassette.runfromapi.md | 26 - kassette.status.code.md | 13 - kassette.status.md | 21 - kassette.status.message.md | 13 - modules.html | 45 + types/ConfigurationPropertySource.html | 2 + types/Delay.html | 6 + types/HarKeyManager.html | 21 + types/Headers.html | 2 + types/IMergedConfiguration.html | 6 + types/ListOrFilter.html | 17 + types/MocksFormat.html | 25 + types/Mode.html | 24 + types/PayloadOrigin.html | 14 + types/ProxyConnectMode.html | 16 + types/RecursiveArray.html | 2 + 318 files changed, 2689 insertions(+), 4764 deletions(-) create mode 100644 assets/highlight.css create mode 100644 assets/main.js create mode 100644 assets/navigation.js create mode 100644 assets/search.js create mode 100644 assets/style.css create mode 100644 functions/runFromAPI.html create mode 100644 index.html delete mode 100644 index.md create mode 100644 interfaces/APIOptions.html create mode 100644 interfaces/CLIConfigurationSpec.html create mode 100644 interfaces/ChecksumArgs.html create mode 100644 interfaces/ConfigurationSpec.html create mode 100644 interfaces/Connection.html create mode 100644 interfaces/ConsoleSpec.html create mode 100644 interfaces/FilterableSpec.html create mode 100644 interfaces/GetConfigurationProps.html create mode 100644 interfaces/HarFormatContent.html create mode 100644 interfaces/HarFormatEntry.html create mode 100644 interfaces/HarFormatNameValuePair.html create mode 100644 interfaces/HarFormatPostData.html create mode 100644 interfaces/HarFormatRequest.html create mode 100644 interfaces/HarFormatResponse.html create mode 100644 interfaces/HarFormatTimings.html create mode 100644 interfaces/HookAPI.html create mode 100644 interfaces/IConfigurationFile.html create mode 100644 interfaces/IConfigurationProperty.html create mode 100644 interfaces/IFetchedRequest.html create mode 100644 interfaces/IMock.html create mode 100644 interfaces/IProxyConnectAPI.html create mode 100644 interfaces/IResponse.html create mode 100644 interfaces/IncludableSpec.html create mode 100644 interfaces/MockData.html create mode 100644 interfaces/MockingOptions.html create mode 100644 interfaces/Payload.html create mode 100644 interfaces/PayloadWithOrigin.html create mode 100644 interfaces/RemotePayload.html create mode 100644 interfaces/RequestPayload.html create mode 100644 interfaces/RequestTimings.html create mode 100644 interfaces/Status.html delete mode 100644 kassette.apioptions.apiconfiguration.md delete mode 100644 kassette.apioptions.configurationpath.md delete mode 100644 kassette.apioptions.fileconfigurationcontext.md delete mode 100644 kassette.apioptions.md delete mode 100644 kassette.checksumargs.body.md delete mode 100644 kassette.checksumargs.customdata.md delete mode 100644 kassette.checksumargs.format.md delete mode 100644 kassette.checksumargs.headers.md delete mode 100644 kassette.checksumargs.hostname.md delete mode 100644 kassette.checksumargs.md delete mode 100644 kassette.checksumargs.method.md delete mode 100644 kassette.checksumargs.pathname.md delete mode 100644 kassette.checksumargs.port.md delete mode 100644 kassette.checksumargs.protocol.md delete mode 100644 kassette.checksumargs.query.md delete mode 100644 kassette.checksumargs.type.md delete mode 100644 kassette.cliconfigurationspec.delay.md delete mode 100644 kassette.cliconfigurationspec.harfilecachetime.md delete mode 100644 kassette.cliconfigurationspec.hostname.md delete mode 100644 kassette.cliconfigurationspec.http2.md delete mode 100644 kassette.cliconfigurationspec.md delete mode 100644 kassette.cliconfigurationspec.mocksfolder.md delete mode 100644 kassette.cliconfigurationspec.mocksformat.md delete mode 100644 kassette.cliconfigurationspec.mocksharfile.md delete mode 100644 kassette.cliconfigurationspec.mode.md delete mode 100644 kassette.cliconfigurationspec.port.md delete mode 100644 kassette.cliconfigurationspec.proxyconnectmode.md delete mode 100644 kassette.cliconfigurationspec.remoteurl.md delete mode 100644 kassette.cliconfigurationspec.savechecksumcontent.md delete mode 100644 kassette.cliconfigurationspec.savedetailedtimings.md delete mode 100644 kassette.cliconfigurationspec.saveforwardedrequestbody.md delete mode 100644 kassette.cliconfigurationspec.saveforwardedrequestdata.md delete mode 100644 kassette.cliconfigurationspec.saveinputrequestbody.md delete mode 100644 kassette.cliconfigurationspec.saveinputrequestdata.md delete mode 100644 kassette.cliconfigurationspec.skiplog.md delete mode 100644 kassette.cliconfigurationspec.tlscakeypath.md delete mode 100644 kassette.cliconfigurationspec.tlskeysize.md delete mode 100644 kassette.configurationpropertysource.md delete mode 100644 kassette.configurationspec.console.md delete mode 100644 kassette.configurationspec.harmimetypesparsejson.md delete mode 100644 kassette.configurationspec.hook.md delete mode 100644 kassette.configurationspec.md delete mode 100644 kassette.configurationspec.mocksharkeymanager.md delete mode 100644 kassette.configurationspec.onexit.md delete mode 100644 kassette.configurationspec.onlisten.md delete mode 100644 kassette.configurationspec.onproxyconnect.md delete mode 100644 kassette.connection.hostname.md delete mode 100644 kassette.connection.md delete mode 100644 kassette.connection.port.md delete mode 100644 kassette.connection.protocol.md delete mode 100644 kassette.consolespec.error.md delete mode 100644 kassette.consolespec.log.md delete mode 100644 kassette.consolespec.md delete mode 100644 kassette.delay.md delete mode 100644 kassette.filterablespec.filter.md delete mode 100644 kassette.filterablespec.md delete mode 100644 kassette.getconfigurationprops.apiconfiguration.md delete mode 100644 kassette.getconfigurationprops.cliconfiguration.md delete mode 100644 kassette.getconfigurationprops.context.md delete mode 100644 kassette.getconfigurationprops.md delete mode 100644 kassette.harformatcontent.comment.md delete mode 100644 kassette.harformatcontent.compression.md delete mode 100644 kassette.harformatcontent.encoding.md delete mode 100644 kassette.harformatcontent.json.md delete mode 100644 kassette.harformatcontent.md delete mode 100644 kassette.harformatcontent.mimetype.md delete mode 100644 kassette.harformatcontent.size.md delete mode 100644 kassette.harformatcontent.text.md delete mode 100644 kassette.harformatentry._kassettechecksumcontent.md delete mode 100644 kassette.harformatentry._kassetteforwardedrequest.md delete mode 100644 kassette.harformatentry._kassettemockkey.md delete mode 100644 kassette.harformatentry.cache.md delete mode 100644 kassette.harformatentry.comment.md delete mode 100644 kassette.harformatentry.connection.md delete mode 100644 kassette.harformatentry.md delete mode 100644 kassette.harformatentry.pageref.md delete mode 100644 kassette.harformatentry.request.md delete mode 100644 kassette.harformatentry.response.md delete mode 100644 kassette.harformatentry.serveripaddress.md delete mode 100644 kassette.harformatentry.starteddatetime.md delete mode 100644 kassette.harformatentry.time.md delete mode 100644 kassette.harformatentry.timings.md delete mode 100644 kassette.harformatnamevaluepair.comment.md delete mode 100644 kassette.harformatnamevaluepair.md delete mode 100644 kassette.harformatnamevaluepair.name.md delete mode 100644 kassette.harformatnamevaluepair.value.md delete mode 100644 kassette.harformatpostdata.comment.md delete mode 100644 kassette.harformatpostdata.json.md delete mode 100644 kassette.harformatpostdata.md delete mode 100644 kassette.harformatpostdata.mimetype.md delete mode 100644 kassette.harformatpostdata.params.md delete mode 100644 kassette.harformatpostdata.text.md delete mode 100644 kassette.harformatrequest.bodysize.md delete mode 100644 kassette.harformatrequest.comment.md delete mode 100644 kassette.harformatrequest.cookies.md delete mode 100644 kassette.harformatrequest.headers.md delete mode 100644 kassette.harformatrequest.headerssize.md delete mode 100644 kassette.harformatrequest.httpversion.md delete mode 100644 kassette.harformatrequest.md delete mode 100644 kassette.harformatrequest.method.md delete mode 100644 kassette.harformatrequest.postdata.md delete mode 100644 kassette.harformatrequest.querystring.md delete mode 100644 kassette.harformatrequest.url.md delete mode 100644 kassette.harformatresponse.bodysize.md delete mode 100644 kassette.harformatresponse.comment.md delete mode 100644 kassette.harformatresponse.content.md delete mode 100644 kassette.harformatresponse.cookies.md delete mode 100644 kassette.harformatresponse.headers.md delete mode 100644 kassette.harformatresponse.headerssize.md delete mode 100644 kassette.harformatresponse.httpversion.md delete mode 100644 kassette.harformatresponse.md delete mode 100644 kassette.harformatresponse.redirecturl.md delete mode 100644 kassette.harformatresponse.status.md delete mode 100644 kassette.harformatresponse.statustext.md delete mode 100644 kassette.harformattimings.comment.md delete mode 100644 kassette.harformattimings.md delete mode 100644 kassette.harkeymanager.md delete mode 100644 kassette.headers_2.md delete mode 100644 kassette.hookapi.console.md delete mode 100644 kassette.hookapi.md delete mode 100644 kassette.hookapi.mock.md delete mode 100644 kassette.iconfigurationfile.getconfiguration.md delete mode 100644 kassette.iconfigurationfile.md delete mode 100644 kassette.iconfigurationproperty.md delete mode 100644 kassette.iconfigurationproperty.origin.md delete mode 100644 kassette.iconfigurationproperty.value.md delete mode 100644 kassette.ifetchedrequest.body.md delete mode 100644 kassette.ifetchedrequest.connection.md delete mode 100644 kassette.ifetchedrequest.connectionsstack.md delete mode 100644 kassette.ifetchedrequest.headers.md delete mode 100644 kassette.ifetchedrequest.hostname.md delete mode 100644 kassette.ifetchedrequest.md delete mode 100644 kassette.ifetchedrequest.method.md delete mode 100644 kassette.ifetchedrequest.original.md delete mode 100644 kassette.ifetchedrequest.pathname.md delete mode 100644 kassette.ifetchedrequest.port.md delete mode 100644 kassette.ifetchedrequest.protocol.md delete mode 100644 kassette.ifetchedrequest.queryparameters.md delete mode 100644 kassette.ifetchedrequest.url.md delete mode 100644 kassette.imergedconfiguration.md delete mode 100644 kassette.imock.checksum.md delete mode 100644 kassette.imock.checksumcontent.md delete mode 100644 kassette.imock.createpayload.md delete mode 100644 kassette.imock.defaultlocalpath.md delete mode 100644 kassette.imock.defaultmockharkey.md delete mode 100644 kassette.imock.delay.md delete mode 100644 kassette.imock.downloadpayload.md delete mode 100644 kassette.imock.fetchpayload.md delete mode 100644 kassette.imock.fillresponsefrompayload.md delete mode 100644 kassette.imock.getpayloadandfillresponse.md delete mode 100644 kassette.imock.harmimetypesparsejson.md delete mode 100644 kassette.imock.haslocalfiles.md delete mode 100644 kassette.imock.haslocalmock.md delete mode 100644 kassette.imock.hasnolocalfiles.md delete mode 100644 kassette.imock.hasnolocalmock.md delete mode 100644 kassette.imock.localpath.md delete mode 100644 kassette.imock.md delete mode 100644 kassette.imock.mockfolderfullpath.md delete mode 100644 kassette.imock.mockharkey.md delete mode 100644 kassette.imock.mocksfolder.md delete mode 100644 kassette.imock.mocksformat.md delete mode 100644 kassette.imock.mocksharfile.md delete mode 100644 kassette.imock.mocksharkeymanager.md delete mode 100644 kassette.imock.mode.md delete mode 100644 kassette.imock.options.md delete mode 100644 kassette.imock.persistpayload.md delete mode 100644 kassette.imock.process.md delete mode 100644 kassette.imock.readlocalpayload.md delete mode 100644 kassette.imock.readlocalpayloadandfillresponse.md delete mode 100644 kassette.imock.readordownloadpayload.md delete mode 100644 kassette.imock.readorfetchpayload.md delete mode 100644 kassette.imock.remoteurl.md delete mode 100644 kassette.imock.request.md delete mode 100644 kassette.imock.response.md delete mode 100644 kassette.imock.savechecksumcontent.md delete mode 100644 kassette.imock.savedetailedtimings.md delete mode 100644 kassette.imock.saveforwardedrequestbody.md delete mode 100644 kassette.imock.saveforwardedrequestdata.md delete mode 100644 kassette.imock.saveinputrequestbody.md delete mode 100644 kassette.imock.saveinputrequestdata.md delete mode 100644 kassette.imock.sendresponse.md delete mode 100644 kassette.imock.setdelay.md delete mode 100644 kassette.imock.setharmimetypesparsejson.md delete mode 100644 kassette.imock.setlocalpath.md delete mode 100644 kassette.imock.setmockharkey.md delete mode 100644 kassette.imock.setmocksfolder.md delete mode 100644 kassette.imock.setmocksformat.md delete mode 100644 kassette.imock.setmocksharfile.md delete mode 100644 kassette.imock.setmocksharkeymanager.md delete mode 100644 kassette.imock.setmode.md delete mode 100644 kassette.imock.setpayload.md delete mode 100644 kassette.imock.setremoteurl.md delete mode 100644 kassette.imock.setsavechecksumcontent.md delete mode 100644 kassette.imock.setsavedetailedtimings.md delete mode 100644 kassette.imock.setsaveforwardedrequestbody.md delete mode 100644 kassette.imock.setsaveforwardedrequestdata.md delete mode 100644 kassette.imock.setsaveinputrequestbody.md delete mode 100644 kassette.imock.setsaveinputrequestdata.md delete mode 100644 kassette.imock.sourcepayload.md delete mode 100644 kassette.includablespec.include.md delete mode 100644 kassette.includablespec.md delete mode 100644 kassette.iproxyconnectapi.connection.md delete mode 100644 kassette.iproxyconnectapi.connectionsstack.md delete mode 100644 kassette.iproxyconnectapi.destinationhostname.md delete mode 100644 kassette.iproxyconnectapi.destinationport.md delete mode 100644 kassette.iproxyconnectapi.hostname.md delete mode 100644 kassette.iproxyconnectapi.md delete mode 100644 kassette.iproxyconnectapi.mode.md delete mode 100644 kassette.iproxyconnectapi.port.md delete mode 100644 kassette.iproxyconnectapi.process.md delete mode 100644 kassette.iproxyconnectapi.request.md delete mode 100644 kassette.iproxyconnectapi.setdestination.md delete mode 100644 kassette.iproxyconnectapi.setmode.md delete mode 100644 kassette.iproxyconnectapi.socket.md delete mode 100644 kassette.iresponse.body.md delete mode 100644 kassette.iresponse.headers.md delete mode 100644 kassette.iresponse.json.md delete mode 100644 kassette.iresponse.md delete mode 100644 kassette.iresponse.original.md delete mode 100644 kassette.iresponse.send.md delete mode 100644 kassette.iresponse.setdata.md delete mode 100644 kassette.iresponse.setheaders.md delete mode 100644 kassette.iresponse.status.md delete mode 100644 kassette.listorfilter.md delete mode 100644 kassette.md delete mode 100644 kassette.mockdata.bodyfilename.md delete mode 100644 kassette.mockdata.creationdatetime.md delete mode 100644 kassette.mockdata.headers.md delete mode 100644 kassette.mockdata.httpversion.md delete mode 100644 kassette.mockdata.ignoredheaders.md delete mode 100644 kassette.mockdata.md delete mode 100644 kassette.mockdata.status.md delete mode 100644 kassette.mockdata.time.md delete mode 100644 kassette.mockdata.timings.md delete mode 100644 kassette.mockingoptions.md delete mode 100644 kassette.mockingoptions.root.md delete mode 100644 kassette.mockingoptions.userconfiguration.md delete mode 100644 kassette.mocksformat.md delete mode 100644 kassette.mode.md delete mode 100644 kassette.payload.body.md delete mode 100644 kassette.payload.data.md delete mode 100644 kassette.payload.md delete mode 100644 kassette.payloadorigin.md delete mode 100644 kassette.payloadwithorigin.md delete mode 100644 kassette.payloadwithorigin.origin.md delete mode 100644 kassette.payloadwithorigin.payload.md delete mode 100644 kassette.proxyconnectmode.md delete mode 100644 kassette.recursivearray.md delete mode 100644 kassette.remotepayload.md delete mode 100644 kassette.remotepayload.requestoptions.md delete mode 100644 kassette.requestpayload.body.md delete mode 100644 kassette.requestpayload.headers.md delete mode 100644 kassette.requestpayload.md delete mode 100644 kassette.requestpayload.method.md delete mode 100644 kassette.requestpayload.url.md delete mode 100644 kassette.requesttimings.blocked.md delete mode 100644 kassette.requesttimings.connect.md delete mode 100644 kassette.requesttimings.dns.md delete mode 100644 kassette.requesttimings.md delete mode 100644 kassette.requesttimings.receive.md delete mode 100644 kassette.requesttimings.send.md delete mode 100644 kassette.requesttimings.ssl.md delete mode 100644 kassette.requesttimings.wait.md delete mode 100644 kassette.runfromapi.md delete mode 100644 kassette.status.code.md delete mode 100644 kassette.status.md delete mode 100644 kassette.status.message.md create mode 100644 modules.html create mode 100644 types/ConfigurationPropertySource.html create mode 100644 types/Delay.html create mode 100644 types/HarKeyManager.html create mode 100644 types/Headers.html create mode 100644 types/IMergedConfiguration.html create mode 100644 types/ListOrFilter.html create mode 100644 types/MocksFormat.html create mode 100644 types/Mode.html create mode 100644 types/PayloadOrigin.html create mode 100644 types/ProxyConnectMode.html create mode 100644 types/RecursiveArray.html diff --git a/assets/highlight.css b/assets/highlight.css new file mode 100644 index 00000000..3dc6e492 --- /dev/null +++ b/assets/highlight.css @@ -0,0 +1,92 @@ +:root { + --light-hl-0: #008000; + --dark-hl-0: #6A9955; + --light-hl-1: #0000FF; + --dark-hl-1: #569CD6; + --light-hl-2: #267F99; + --dark-hl-2: #4EC9B0; + --light-hl-3: #000000; + --dark-hl-3: #D4D4D4; + --light-hl-4: #795E26; + --dark-hl-4: #DCDCAA; + --light-hl-5: #AF00DB; + --dark-hl-5: #C586C0; + --light-hl-6: #001080; + --dark-hl-6: #9CDCFE; + --light-hl-7: #098658; + --dark-hl-7: #B5CEA8; + --light-hl-8: #A31515; + --dark-hl-8: #CE9178; + --light-hl-9: #0070C1; + --dark-hl-9: #4FC1FF; + --light-code-background: #FFFFFF; + --dark-code-background: #1E1E1E; +} + +@media (prefers-color-scheme: light) { :root { + --hl-0: var(--light-hl-0); + --hl-1: var(--light-hl-1); + --hl-2: var(--light-hl-2); + --hl-3: var(--light-hl-3); + --hl-4: var(--light-hl-4); + --hl-5: var(--light-hl-5); + --hl-6: var(--light-hl-6); + --hl-7: var(--light-hl-7); + --hl-8: var(--light-hl-8); + --hl-9: var(--light-hl-9); + --code-background: var(--light-code-background); +} } + +@media (prefers-color-scheme: dark) { :root { + --hl-0: var(--dark-hl-0); + --hl-1: var(--dark-hl-1); + --hl-2: var(--dark-hl-2); + --hl-3: var(--dark-hl-3); + --hl-4: var(--dark-hl-4); + --hl-5: var(--dark-hl-5); + --hl-6: var(--dark-hl-6); + --hl-7: var(--dark-hl-7); + --hl-8: var(--dark-hl-8); + --hl-9: var(--dark-hl-9); + --code-background: var(--dark-code-background); +} } + +:root[data-theme='light'] { + --hl-0: var(--light-hl-0); + --hl-1: var(--light-hl-1); + --hl-2: var(--light-hl-2); + --hl-3: var(--light-hl-3); + --hl-4: var(--light-hl-4); + --hl-5: var(--light-hl-5); + --hl-6: var(--light-hl-6); + --hl-7: var(--light-hl-7); + --hl-8: var(--light-hl-8); + --hl-9: var(--light-hl-9); + --code-background: var(--light-code-background); +} + +:root[data-theme='dark'] { + --hl-0: var(--dark-hl-0); + --hl-1: var(--dark-hl-1); + --hl-2: var(--dark-hl-2); + --hl-3: var(--dark-hl-3); + --hl-4: var(--dark-hl-4); + --hl-5: var(--dark-hl-5); + --hl-6: var(--dark-hl-6); + --hl-7: var(--dark-hl-7); + --hl-8: var(--dark-hl-8); + --hl-9: var(--dark-hl-9); + --code-background: var(--dark-code-background); +} + +.hl-0 { color: var(--hl-0); } +.hl-1 { color: var(--hl-1); } +.hl-2 { color: var(--hl-2); } +.hl-3 { color: var(--hl-3); } +.hl-4 { color: var(--hl-4); } +.hl-5 { color: var(--hl-5); } +.hl-6 { color: var(--hl-6); } +.hl-7 { color: var(--hl-7); } +.hl-8 { color: var(--hl-8); } +.hl-9 { color: var(--hl-9); } +pre, code { background: var(--code-background); } diff --git a/assets/main.js b/assets/main.js new file mode 100644 index 00000000..d0aa8d5f --- /dev/null +++ b/assets/main.js @@ -0,0 +1,59 @@ +"use strict"; +"use strict";(()=>{var Pe=Object.create;var ne=Object.defineProperty;var Ie=Object.getOwnPropertyDescriptor;var Oe=Object.getOwnPropertyNames;var _e=Object.getPrototypeOf,Re=Object.prototype.hasOwnProperty;var Me=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Fe=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Oe(e))!Re.call(t,i)&&i!==n&&ne(t,i,{get:()=>e[i],enumerable:!(r=Ie(e,i))||r.enumerable});return t};var De=(t,e,n)=>(n=t!=null?Pe(_e(t)):{},Fe(e||!t||!t.__esModule?ne(n,"default",{value:t,enumerable:!0}):n,t));var ae=Me((se,oe)=>{(function(){var t=function(e){var n=new t.Builder;return n.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),n.searchPipeline.add(t.stemmer),e.call(n,n),n.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(n){e.console&&console.warn&&console.warn(n)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var n=Object.create(null),r=Object.keys(e),i=0;i0){var d=t.utils.clone(n)||{};d.position=[a,u],d.index=s.length,s.push(new t.Token(r.slice(a,o),d))}a=o+1}}return s},t.tokenizer.separator=/[\s\-]+/;t.Pipeline=function(){this._stack=[]},t.Pipeline.registeredFunctions=Object.create(null),t.Pipeline.registerFunction=function(e,n){n in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+n),e.label=n,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var n=e.label&&e.label in this.registeredFunctions;n||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. +`,e)},t.Pipeline.load=function(e){var n=new t.Pipeline;return e.forEach(function(r){var i=t.Pipeline.registeredFunctions[r];if(i)n.add(i);else throw new Error("Cannot load unregistered function: "+r)}),n},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(n){t.Pipeline.warnIfFunctionNotRegistered(n),this._stack.push(n)},this)},t.Pipeline.prototype.after=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");r=r+1,this._stack.splice(r,0,n)},t.Pipeline.prototype.before=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");this._stack.splice(r,0,n)},t.Pipeline.prototype.remove=function(e){var n=this._stack.indexOf(e);n!=-1&&this._stack.splice(n,1)},t.Pipeline.prototype.run=function(e){for(var n=this._stack.length,r=0;r1&&(oe&&(r=s),o!=e);)i=r-n,s=n+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(ol?d+=2:a==l&&(n+=r[u+1]*i[d+1],u+=2,d+=2);return n},t.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},t.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),n=1,r=0;n0){var o=s.str.charAt(0),a;o in s.node.edges?a=s.node.edges[o]:(a=new t.TokenSet,s.node.edges[o]=a),s.str.length==1&&(a.final=!0),i.push({node:a,editsRemaining:s.editsRemaining,str:s.str.slice(1)})}if(s.editsRemaining!=0){if("*"in s.node.edges)var l=s.node.edges["*"];else{var l=new t.TokenSet;s.node.edges["*"]=l}if(s.str.length==0&&(l.final=!0),i.push({node:l,editsRemaining:s.editsRemaining-1,str:s.str}),s.str.length>1&&i.push({node:s.node,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)}),s.str.length==1&&(s.node.final=!0),s.str.length>=1){if("*"in s.node.edges)var u=s.node.edges["*"];else{var u=new t.TokenSet;s.node.edges["*"]=u}s.str.length==1&&(u.final=!0),i.push({node:u,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)})}if(s.str.length>1){var d=s.str.charAt(0),v=s.str.charAt(1),f;v in s.node.edges?f=s.node.edges[v]:(f=new t.TokenSet,s.node.edges[v]=f),s.str.length==1&&(f.final=!0),i.push({node:f,editsRemaining:s.editsRemaining-1,str:d+s.str.slice(2)})}}}return r},t.TokenSet.fromString=function(e){for(var n=new t.TokenSet,r=n,i=0,s=e.length;i=e;n--){var r=this.uncheckedNodes[n],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(n){var r=new t.QueryParser(e,n);r.parse()})},t.Index.prototype.query=function(e){for(var n=new t.Query(this.fields),r=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),l=0;l1?this._b=1:this._b=e},t.Builder.prototype.k1=function(e){this._k1=e},t.Builder.prototype.add=function(e,n){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=n||{},this.documentCount+=1;for(var s=0;s=this.length)return t.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},t.QueryLexer.prototype.width=function(){return this.pos-this.start},t.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},t.QueryLexer.prototype.backup=function(){this.pos-=1},t.QueryLexer.prototype.acceptDigitRun=function(){var e,n;do e=this.next(),n=e.charCodeAt(0);while(n>47&&n<58);e!=t.QueryLexer.EOS&&this.backup()},t.QueryLexer.prototype.more=function(){return this.pos1&&(e.backup(),e.emit(t.QueryLexer.TERM)),e.ignore(),e.more())return t.QueryLexer.lexText},t.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.EDIT_DISTANCE),t.QueryLexer.lexText},t.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.BOOST),t.QueryLexer.lexText},t.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(t.QueryLexer.TERM)},t.QueryLexer.termSeparator=t.tokenizer.separator,t.QueryLexer.lexText=function(e){for(;;){var n=e.next();if(n==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(n.charCodeAt(0)==92){e.escapeCharacter();continue}if(n==":")return t.QueryLexer.lexField;if(n=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(n=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(n=="+"&&e.width()===1||n=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(n.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,n){this.lexer=new t.QueryLexer(e),this.query=n,this.currentClause={},this.lexemeIdx=0},t.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=t.QueryParser.parseClause;e;)e=e(this);return this.query},t.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},t.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},t.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},t.QueryParser.parseClause=function(e){var n=e.peekLexeme();if(n!=null)switch(n.type){case t.QueryLexer.PRESENCE:return t.QueryParser.parsePresence;case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expected either a field or a term, found "+n.type;throw n.str.length>=1&&(r+=" with value '"+n.str+"'"),new t.QueryParseError(r,n.start,n.end)}},t.QueryParser.parsePresence=function(e){var n=e.consumeLexeme();if(n!=null){switch(n.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator'"+n.str+"'";throw new t.QueryParseError(r,n.start,n.end)}var i=e.peekLexeme();if(i==null){var r="expecting term or field, found nothing";throw new t.QueryParseError(r,n.start,n.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(r,i.start,i.end)}}},t.QueryParser.parseField=function(e){var n=e.consumeLexeme();if(n!=null){if(e.query.allFields.indexOf(n.str)==-1){var r=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+n.str+"', possible fields: "+r;throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.fields=[n.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,n.start,n.end)}switch(s.type){case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var i="expecting term, found '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseTerm=function(e){var n=e.consumeLexeme();if(n!=null){e.currentClause.term=n.str.toLowerCase(),n.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(r==null){e.nextClause();return}switch(r.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+r.type+"'";throw new t.QueryParseError(i,r.start,r.end)}}},t.QueryParser.parseEditDistance=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.editDistance=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseBoost=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="boost must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.boost=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},function(e,n){typeof define=="function"&&define.amd?define(n):typeof se=="object"?oe.exports=n():e.lunr=n()}(this,function(){return t})})()});var re=[];function G(t,e){re.push({selector:e,constructor:t})}var U=class{constructor(){this.alwaysVisibleMember=null;this.createComponents(document.body),this.ensureActivePageVisible(),this.ensureFocusedElementVisible(),this.listenForCodeCopies(),window.addEventListener("hashchange",()=>this.ensureFocusedElementVisible())}createComponents(e){re.forEach(n=>{e.querySelectorAll(n.selector).forEach(r=>{r.dataset.hasInstance||(new n.constructor({el:r,app:this}),r.dataset.hasInstance=String(!0))})})}filterChanged(){this.ensureFocusedElementVisible()}ensureActivePageVisible(){let e=document.querySelector(".tsd-navigation .current"),n=e?.parentElement;for(;n&&!n.classList.contains(".tsd-navigation");)n instanceof HTMLDetailsElement&&(n.open=!0),n=n.parentElement;if(e){let r=e.getBoundingClientRect().top-document.documentElement.clientHeight/4;document.querySelector(".site-menu").scrollTop=r}}ensureFocusedElementVisible(){if(this.alwaysVisibleMember&&(this.alwaysVisibleMember.classList.remove("always-visible"),this.alwaysVisibleMember.firstElementChild.remove(),this.alwaysVisibleMember=null),!location.hash)return;let e=document.getElementById(location.hash.substring(1));if(!e)return;let n=e.parentElement;for(;n&&n.tagName!=="SECTION";)n=n.parentElement;if(n&&n.offsetParent==null){this.alwaysVisibleMember=n,n.classList.add("always-visible");let r=document.createElement("p");r.classList.add("warning"),r.textContent="This member is normally hidden due to your filter settings.",n.prepend(r)}}listenForCodeCopies(){document.querySelectorAll("pre > button").forEach(e=>{let n;e.addEventListener("click",()=>{e.previousElementSibling instanceof HTMLElement&&navigator.clipboard.writeText(e.previousElementSibling.innerText.trim()),e.textContent="Copied!",e.classList.add("visible"),clearTimeout(n),n=setTimeout(()=>{e.classList.remove("visible"),n=setTimeout(()=>{e.textContent="Copy"},100)},1e3)})})}};var ie=(t,e=100)=>{let n;return()=>{clearTimeout(n),n=setTimeout(()=>t(),e)}};var de=De(ae());async function le(t,e){if(!window.searchData)return;let n=await fetch(window.searchData),r=new Blob([await n.arrayBuffer()]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();t.data=i,t.index=de.Index.load(i.index),e.classList.remove("loading"),e.classList.add("ready")}function he(){let t=document.getElementById("tsd-search");if(!t)return;let e={base:t.dataset.base+"/"},n=document.getElementById("tsd-search-script");t.classList.add("loading"),n&&(n.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),n.addEventListener("load",()=>{le(e,t)}),le(e,t));let r=document.querySelector("#tsd-search input"),i=document.querySelector("#tsd-search .results");if(!r||!i)throw new Error("The input field or the result list wrapper was not found");let s=!1;i.addEventListener("mousedown",()=>s=!0),i.addEventListener("mouseup",()=>{s=!1,t.classList.remove("has-focus")}),r.addEventListener("focus",()=>t.classList.add("has-focus")),r.addEventListener("blur",()=>{s||(s=!1,t.classList.remove("has-focus"))}),Ae(t,i,r,e)}function Ae(t,e,n,r){n.addEventListener("input",ie(()=>{Ne(t,e,n,r)},200));let i=!1;n.addEventListener("keydown",s=>{i=!0,s.key=="Enter"?Ve(e,n):s.key=="Escape"?n.blur():s.key=="ArrowUp"?ue(e,-1):s.key==="ArrowDown"?ue(e,1):i=!1}),n.addEventListener("keypress",s=>{i&&s.preventDefault()}),document.body.addEventListener("keydown",s=>{s.altKey||s.ctrlKey||s.metaKey||!n.matches(":focus")&&s.key==="/"&&(n.focus(),s.preventDefault())})}function Ne(t,e,n,r){if(!r.index||!r.data)return;e.textContent="";let i=n.value.trim(),s;if(i){let o=i.split(" ").map(a=>a.length?`*${a}*`:"").join(" ");s=r.index.search(o)}else s=[];for(let o=0;oa.score-o.score);for(let o=0,a=Math.min(10,s.length);o`,d=ce(l.name,i);globalThis.DEBUG_SEARCH_WEIGHTS&&(d+=` (score: ${s[o].score.toFixed(2)})`),l.parent&&(d=` + ${ce(l.parent,i)}.${d}`);let v=document.createElement("li");v.classList.value=l.classes??"";let f=document.createElement("a");f.href=r.base+l.url,f.innerHTML=u+d,v.append(f),e.appendChild(v)}}function ue(t,e){let n=t.querySelector(".current");if(!n)n=t.querySelector(e==1?"li:first-child":"li:last-child"),n&&n.classList.add("current");else{let r=n;if(e===1)do r=r.nextElementSibling??void 0;while(r instanceof HTMLElement&&r.offsetParent==null);else do r=r.previousElementSibling??void 0;while(r instanceof HTMLElement&&r.offsetParent==null);r&&(n.classList.remove("current"),r.classList.add("current"))}}function Ve(t,e){let n=t.querySelector(".current");if(n||(n=t.querySelector("li:first-child")),n){let r=n.querySelector("a");r&&(window.location.href=r.href),e.blur()}}function ce(t,e){if(e==="")return t;let n=t.toLocaleLowerCase(),r=e.toLocaleLowerCase(),i=[],s=0,o=n.indexOf(r);for(;o!=-1;)i.push(K(t.substring(s,o)),`${K(t.substring(o,o+r.length))}`),s=o+r.length,o=n.indexOf(r,s);return i.push(K(t.substring(s))),i.join("")}var Be={"&":"&","<":"<",">":">","'":"'",'"':"""};function K(t){return t.replace(/[&<>"'"]/g,e=>Be[e])}var C=class{constructor(e){this.el=e.el,this.app=e.app}};var F="mousedown",pe="mousemove",B="mouseup",J={x:0,y:0},fe=!1,ee=!1,He=!1,D=!1,me=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(me?"is-mobile":"not-mobile");me&&"ontouchstart"in document.documentElement&&(He=!0,F="touchstart",pe="touchmove",B="touchend");document.addEventListener(F,t=>{ee=!0,D=!1;let e=F=="touchstart"?t.targetTouches[0]:t;J.y=e.pageY||0,J.x=e.pageX||0});document.addEventListener(pe,t=>{if(ee&&!D){let e=F=="touchstart"?t.targetTouches[0]:t,n=J.x-(e.pageX||0),r=J.y-(e.pageY||0);D=Math.sqrt(n*n+r*r)>10}});document.addEventListener(B,()=>{ee=!1});document.addEventListener("click",t=>{fe&&(t.preventDefault(),t.stopImmediatePropagation(),fe=!1)});var X=class extends C{constructor(n){super(n);this.className=this.el.dataset.toggle||"",this.el.addEventListener(B,r=>this.onPointerUp(r)),this.el.addEventListener("click",r=>r.preventDefault()),document.addEventListener(F,r=>this.onDocumentPointerDown(r)),document.addEventListener(B,r=>this.onDocumentPointerUp(r))}setActive(n){if(this.active==n)return;this.active=n,document.documentElement.classList.toggle("has-"+this.className,n),this.el.classList.toggle("active",n);let r=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(r),setTimeout(()=>document.documentElement.classList.remove(r),500)}onPointerUp(n){D||(this.setActive(!0),n.preventDefault())}onDocumentPointerDown(n){if(this.active){if(n.target.closest(".col-sidebar, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(n){if(!D&&this.active&&n.target.closest(".col-sidebar")){let r=n.target.closest("a");if(r){let i=window.location.href;i.indexOf("#")!=-1&&(i=i.substring(0,i.indexOf("#"))),r.href.substring(0,i.length)==i&&setTimeout(()=>this.setActive(!1),250)}}}};var te;try{te=localStorage}catch{te={getItem(){return null},setItem(){}}}var Q=te;var ve=document.head.appendChild(document.createElement("style"));ve.dataset.for="filters";var Y=class extends C{constructor(n){super(n);this.key=`filter-${this.el.name}`,this.value=this.el.checked,this.el.addEventListener("change",()=>{this.setLocalStorage(this.el.checked)}),this.setLocalStorage(this.fromLocalStorage()),ve.innerHTML+=`html:not(.${this.key}) .tsd-is-${this.el.name} { display: none; } +`}fromLocalStorage(){let n=Q.getItem(this.key);return n?n==="true":this.el.checked}setLocalStorage(n){Q.setItem(this.key,n.toString()),this.value=n,this.handleValueChange()}handleValueChange(){this.el.checked=this.value,document.documentElement.classList.toggle(this.key,this.value),this.app.filterChanged(),document.querySelectorAll(".tsd-index-section").forEach(n=>{n.style.display="block";let r=Array.from(n.querySelectorAll(".tsd-index-link")).every(i=>i.offsetParent==null);n.style.display=r?"none":"block"})}};var Z=class extends C{constructor(n){super(n);this.summary=this.el.querySelector(".tsd-accordion-summary"),this.icon=this.summary.querySelector("svg"),this.key=`tsd-accordion-${this.summary.dataset.key??this.summary.textContent.trim().replace(/\s+/g,"-").toLowerCase()}`;let r=Q.getItem(this.key);this.el.open=r?r==="true":this.el.open,this.el.addEventListener("toggle",()=>this.update());let i=this.summary.querySelector("a");i&&i.addEventListener("click",()=>{location.assign(i.href)}),this.update()}update(){this.icon.style.transform=`rotate(${this.el.open?0:-90}deg)`,Q.setItem(this.key,this.el.open.toString())}};function ge(t){let e=Q.getItem("tsd-theme")||"os";t.value=e,ye(e),t.addEventListener("change",()=>{Q.setItem("tsd-theme",t.value),ye(t.value)})}function ye(t){document.documentElement.dataset.theme=t}var Le;function be(){let t=document.getElementById("tsd-nav-script");t&&(t.addEventListener("load",xe),xe())}async function xe(){let t=document.getElementById("tsd-nav-container");if(!t||!window.navigationData)return;let n=await(await fetch(window.navigationData)).arrayBuffer(),r=new Blob([n]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();Le=t.dataset.base+"/",t.innerHTML="";for(let s of i)we(s,t,[]);window.app.createComponents(t),window.app.ensureActivePageVisible()}function we(t,e,n){let r=e.appendChild(document.createElement("li"));if(t.children){let i=[...n,t.text],s=r.appendChild(document.createElement("details"));s.className=t.class?`${t.class} tsd-index-accordion`:"tsd-index-accordion",s.dataset.key=i.join("$");let o=s.appendChild(document.createElement("summary"));o.className="tsd-accordion-summary",o.innerHTML='',Ee(t,o);let a=s.appendChild(document.createElement("div"));a.className="tsd-accordion-details";let l=a.appendChild(document.createElement("ul"));l.className="tsd-nested-navigation";for(let u of t.children)we(u,l,i)}else Ee(t,r,t.class)}function Ee(t,e,n){if(t.path){let r=e.appendChild(document.createElement("a"));r.href=Le+t.path,n&&(r.className=n),location.href===r.href&&r.classList.add("current"),t.kind&&(r.innerHTML=``),r.appendChild(document.createElement("span")).textContent=t.text}else e.appendChild(document.createElement("span")).textContent=t.text}G(X,"a[data-toggle]");G(Z,".tsd-index-accordion");G(Y,".tsd-filter-item input[type=checkbox]");var Se=document.getElementById("tsd-theme");Se&&ge(Se);var je=new U;Object.defineProperty(window,"app",{value:je});he();be();})(); +/*! Bundled license information: + +lunr/lunr.js: + (** + * lunr - http://lunrjs.com - A bit like Solr, but much smaller and not as bright - 2.3.9 + * Copyright (C) 2020 Oliver Nightingale + * @license MIT + *) + (*! + * lunr.utils + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Set + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.tokenizer + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Pipeline + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Vector + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.stemmer + * Copyright (C) 2020 Oliver Nightingale + * Includes code from - http://tartarus.org/~martin/PorterStemmer/js.txt + *) + (*! + * lunr.stopWordFilter + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.trimmer + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.TokenSet + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Index + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Builder + * Copyright (C) 2020 Oliver Nightingale + *) +*/ diff --git a/assets/navigation.js b/assets/navigation.js new file mode 100644 index 00000000..66a6ac59 --- /dev/null +++ b/assets/navigation.js @@ -0,0 +1 @@ +window.navigationData = "data:application/octet-stream;base64,H4sIAAAAAAAAA5WWTY/TMBCG/0vOFQsrdhG9VbuUjdjSqEVwQBxMMk2tJnYYT9BGaP87StOyseOOzTXvM08cZ/zx/U9C8ETJPFlk6bohqZVJZkkjaJ/ME6kIcCdyMFcv8as91VUySw5SFcn8+ub2efZPcveY3mm1k2WLooe3DeRenQ9kxXvID6atF1j6xzcGWFHc8P5rbFopyHvykusUByRGV8CN6JxzmqWsCFD8ZEw2wsk+AlkTkaFu/LPvJTn1g8Clxlr0ZQSKvFYXihJ+UIQdrzsiUbLPooavomohExJ5qYVGyTNt6F6Q4L1nKkq5gV8tmMBsnqBIoWm0MhAyDlSU8ouspbqwil2IFWp9WGSp3zNkXLm9/yxl5f/GKRYv7VcBIPm70Y+y8iVQvoeC+8kOw+pWOj/4JX3Clmaon7rTxnbpH7gQK2T7LI3pr1TlVVuwO5+NcLJ+Ai4uzXMYEkhVcieqjXCyTHSVFoXXcsoiyr9J2q9RltJ/TE0oTrmBWhNw47IIXnXsVN41RiJk3BZjI5xsS4Jav2SIou8Z59W91S3mox6nrnEvGzbqvOH1+3dvbq5Hb7mHSnSu7/gwVPkg8BN0K6FECegarDBoAlEAmoljeByqTleAJRTWHLgqHxPyPkpDaxzuOq5vnIU8/So1w5nkakZR2FJMfnv/LFR3anl32Q4CKwyaRpuxbzRuHvJtIG/RyN+wQJy2oJ2GXNiqJeraOkh2rTremc3VS2p7bt8+//gLlY1FW78MAAA=" \ No newline at end of file diff --git a/assets/search.js b/assets/search.js new file mode 100644 index 00000000..ca181315 --- /dev/null +++ b/assets/search.js @@ -0,0 +1 @@ +window.searchData = "data:application/octet-stream;base64,H4sIAAAAAAAAA7Vd35PjNo7+X9yvrokJ/Z632WTnMpdkM5XJ7T10pVJaW93tbbflldSTzKXyv1+RlGwQAihKdp7SGZMAyQ8EgY+Q9MeqqX9rV2/v/1g974+71VtI0vXqWL5Uq7erdx8//Hjq9vWxXa1Xr81h9Xa1P3ZV81Buq/ary69vnrqXw2q92h7Ktq3a1dvV6s/1IFBtID5LLE/7r+vjw/7xtSl11wC5d0wfpGi9OpVNdezc4Qrqt1jOx7J7CtHPdVo6gIf9oXIm83V97Krfu5BxePrOGA7G9+unavvcvr68ax5ZhPHv4Rh3X05VkLS7viU/emdw0nLWzUvJLt5Y2bntcnWnpu7qbX0IU4haL1f5VLed+TNIJWp9xSzrJnBJ+5bLVb1U3VO9C1N2bnvFzMruKXwxUevlKv9V776EqetbLlf1n9eqCdQ1NL3CLqtyVzVhXuPu0ni5wu1r29Uv35RdGabTaT9LreMhv//guNxPp2rL6mfahXvM9nl/+r5+nCX47tJJmB039LlbXtTu3/ozVHsdnKh+2tHNGMJLvZupvu9xC9Xb5/a9fIp5RoA7Xj+QtvxcDfvBxBXHmQPiBdxmYN9UXbk/VLuf9y/7oxCqeAc2FnCbgX04nl67n6r/vFZtJ7om78gYCbcf2t+kQyh4aH/zHk4zh/a+bn4rm121u2rlBCl/zRCXraAg5foh7qpDOXM8Q5eb+azDrmoW+ay+440G8m3ZvN8fZvtvp+cNTjEr6+ty+1T9vJ99mo17Xz+kpnqpu+p/fvp+3lhwtxsEFk39+5ev6+Ox2nY/zD5mmd7XD6k7tF+/+676IqX/8nBIz5sM5bvqy6f9/81cF6ffDYy3604w02L7LouUw6bIVAKXINshWJr6VDXdl0/1a7O9rIumCtqvPC290bYT0gfF87OCedjEOQpo6+dwkXd9c2Eh57rC76ovP5TH8lFwzX5v6HSePyBnFQw85807YzCjjlcP5Pt921Us0ygO4dzlauV//30/b/Z9hyvtYVsf21o4FXnNlx5Xqn4qmx/2L9XPesN+LJu2+u+W53nlw5Dtf+WwfDn2wgT76ux6SWp9k7x6aVJ9dUa9JJ2+VS59RSJ96yz6Bin0rfPnGyTPN8+cb5E23zxnvkXC/Jdky7dKlf+SPPlWSfL1GfKi9PhWufEVifHNsuJrUuKb5sPXJsO3yYQXp8E3zYGvTYBvlv1ek/reKO9dnvRen/EuSnd96YCbeWoghbKHy6/hF0feC2lXXsB19GV4y2JKR11IMDmhzhM3uzObCJjHaggqOvHxMAHDz+EcwEFMNBxZdwd/enEel6CmappaOmdcRUPLeapcmuYb50i1hIz5t2Dq5f3+0FVN+S95td0W4Qv+YPoFSrw7t+aXgwxTsM79cXt45b05p/PSfKZSvID/VXUjCowN59mG4X5le5gu05JV3DHd+Unz87midswzqOAyslmD2sr1W74FmqjcmhoCtolv6/r53ccP3Aj6n8Jx10HglKC7vhE/8mE083kpR8cUGzVWg5fEZZ+lQHjcKtzfPBKAZsi/Y/ryk2SmETLfgRefHtPQMtxAPpeH14DFdATfDZ1CZnkevDCAutk/7gOW2x3BudfCITiL/b7qtk/ndJUditskfHntOEs2nuOE3qEOwtTIaOV92UdJ7aeu5J0AOwCm440GsmAI1yrX+kK12rZXqfPU0LEqp8roAtWa4r+PZVO+VN0c9eN+Vw3Dl7uw+icTmNBl92Qx/LpPpTKhMxbyGX62vqQmUKFcXsuqnKiwDZ2lp8iWn+lUnW2gYqnUllXqrbaVFdKc6MMPVfNY7fhYwKZIXJPgjOnDD0JEZn4IP1gaz2F1lnR3aSWsixmNqKI91ceWxx3rODdboKSWH0dBOi6tFqiQ7q6QfO99FRXuxI1tJVKASP6l1SIcPGynA8QUwzk1k58CNZGmC+YksvlIi5/Bn5rLNwEaULNFduW9GnDMa/o6YNrKQrWNGi+dm+fOgU5u6p4haHZh+satF9nfQ/l6MIJsncykLY7bL1zWIH0v8xVxSxqki7a9wlz81UqM0QRUKIWaTrBuqc+CeQeXxiD188phpmb/7YIReLotWINDvS0P0u0T0orbLd+x3wdqY5ovtGvrRt+/HkLUsh0WKN5O15wgrePWC4xpEBKoa7HFhiJImi5Q9lS2RoI+JqYiTNp2mbp/1HMUktZXzHA6qbgjTa+aX5g6t/HyAEuq/xoHWN6ar8AAK0DbqPGCuQUWlmGtM4rJpub6ab52qdPCuQdUsJG5h1athcx9pnap08K5h5TKkckHl8eFzH6ufrHXDeYv1Zd55u+tJ5s7/xD9Yq+F8w8tACRrMKvoL2QdlozD2/NG6xFoE7PqDJesR7ht3G4oTVXu+rDny6Euea4Xcz6j5guUnqqm3bddmMpR4wUKHzQdG6aONF0S2DZV2VVh2mjbZcYUpstpuEDRrv7tqHuHaRu3XmidPzbfzFIs9Vms/n248bAdlngp80RaIKyk7ZLtsT8cfupp9fdN/RK4U8ReC4bweDbOd8fdeyR5YhC+fjdwh/MGM9170f4+7gL1k6ZLPHNTb6t2KkC9tApUgS+kTBmbr4TPbRF+ReWpp2NETtbTkYEKs8HPGgpFVLTNbS7dOKHT9290uKL/2T5XM/Se21+nNqiIhB1AeBXJ7KEsGcTV6r0lBqzy6RqDQNVikQGr1l9lEKhyV7Xd/mgutr+dPXG+880G9HHWcow7zh7I+GLxLHLGhqT9rlsP8UqbVe6/3Q6fuXjRLU3Zf+cdqNh3BPJbYOo09CjGR4n3kB9+vFEpoCMuoAjwPDbpwOjK7pVfM1fVueFCRf+WrptcNf/2Xi9NKRELgVwl/hIgRsloa0sECFmzaoLwmJqPr07QVTVZIRgwq2+DtTmNFys88okKVXX0ZCasErdQS7/R4cfmvfuYiC3Qwj8FF2bpEFnCf/gtfLPr58v+qYkSfnc4Au/cxvySnIc336SIsgmApxTtH491U+08RuXqG7VfplbvbX1R9g8hFnGVktbLVMo+1FU24UKn1HTC07Suks734GyACumaY6TFe7UxpcjQZ/v6+E3ZiU8JuxqZHsGq6fbdHx89b7d2W8xI+uqaDTgZeXd9W3kGaIhSyXpbNZNPonC6uY4zB0J9rBPwWd+q/2niqRoqY3ytOog6/xLspT1MWP9TOLA7wdtjQXc730E/jGZm2OIo8AYtYwV0efsWP7pP0dgFdn6bu8T/u++efhSfzRk1mhsHhwudetZnPF6xjn3Kdqjm0wSD6lM9Akp6aUCPFfk5GC5biOvZF06D2VyXx6GOBd+NOvHr5o55tp0wiidsJEihxz4YjVO2Ial0sTPL5QUPtwhHT3jwiRHnfe6JDHD2UymcvomHUsJUesJdTudU0BumVPLnnEavWxfVpWj/vR71JQ7msB9ej5ZS/eryY7Cf+CRGs/aXcNvaCjQQknO39TE//VBEa2rb8nFSw6VZoBJm43nKf9wW4Yvzr4Om3n2bAYu8uzT3WsowUCmSkRz0WOHO65ZDlG3lN0ByCi/Nr1EqsQqcRi+1EKbut5J/ySOnrm97jbqm2lb7z6zJcxovza9a0tZ3RLgr2k4eEWNlzisNysYG+p4dR9vMcUgvL0IFIyv07tKBn9NouPM3O694aruHKhY2PK/Ut+VDFXo2vbTE/m0fqlja+LxW79YPVSltfl6ld/uHqvQ4AF7rlAsIXl7eCQir63EDHoWsI/j7seO/beO2CHcCvz7rFl0XUtfM6Ljz9J+YsZ3K1LA02yE8i+UdzqXfTYZBKxVnj4cRcM3ATvrhq+ohdBiX5tcobbuy6aqdj6XklI+7XTMIifflNHvZ3zB1ntoVTuNU5UqoUvkKldc6USwVpnarXzUZqnNofCWWk2GNC6eXZg+04qr5XDUfPr7b7Rrhgpy14lG3q5baW5fDrvd0VU6o6umwz9EbGPRRpez59bGW6+VHjcJPsZf+ocxwsXeoy8TEzmMWfXFTvvjtyFV97nClYumFa4Ja75vWgpWGmI+rN9iCplRLRROCXm/xhE8pa7khB//s91zJFCArc4oEHA12Hs3J6/QRnaEKJ+71ecUh9/uhA9jW9fOef7iUV37pcOXMZcZVmPUE5xqq2Lyl6lPX7I/sK1h55W6n6wZwCnH15FVPE49EzVx06cXK3oX3vlg5dACaxp6nHfW41tKn/TOx9ED3zLwFineUAcHr/DpAuayEFzpVXzIer1fxz1NnLaf856ATd7LsLdh5OiVw87ynfwhh7hOrn+E/Fxf9STMP96BTs56mQuisA8mPKdVNtds31bYTXiolqHd73WbhA9wYs/ihrmy6gHWm/jl+dAr9EEfqoh/sScd1mpwr1XV4/9Qvjf1Y7tnX8/Atw52q9IiCR+6d98kEYeiCevEtuj79/rfozhtACMbMEIKBlgbBoh3CvPZtZhybU9sHS7xrg3bOMFB5UU+aIpk6rxzNbqfrBhDEBjjaw8mACdWTKbmjNiwjn1BZHbf1birKd9SiHlcjPbl9KMphG2dC8SQT4GgNIwLGKmktGv+2NFuI5vzm3Z5pkkSX3f/rrx22VEnY3bmdOAs0NHkKP1Xb16bdf67eNc3oIxbuj7PKVWldez8P+6+cpF/Wq/1xV/2+evvH6nMfpr5dwZvoTbFarx721WHXrt7eDyfUYDi/9L/9s9p2daNb2CZfbVbr+806gTeFSn/5ZX0/9DA/mH8wzdRqfa/WcfYm3+ROM+U0g9X6Hjhp4DSLVuv7iGsWOc3i1fo+5prFTrNktb5PuGaJ0yxdre9TrlnqNMtW6/tsHcdv4jhymmVOs3y1vs/XUf4GErdZ7jQrVuv7gmtWuMurV1tt1rF6U7jtFMHBAMEj4UKh9JIrWEfFmwKITBcNpVddsXgoFxClF17F6yh5k2RuQxcSpZdesaAoFxWlV1+xuCgXGKUBUBk7dRcblUurrlx0VCGhqFx8wOCTc4sJLkBgACoYJIFsFbNXNpylgYsPaBBAsS1dfECjAMC2dAECjQJEbEsXINAoQMy2dAECjQIkbEsXINAwQMotkgsQaBiA3Y7gIhRpGCDnWkYuQpHGAQrOjiIXokjjELEQRcShGY/GQhS5EEUahwhY7S5EkcYhitiWLkSRxiGK2ZYuRJHGIWL3ZeRCFGkgInZfRi5GkQYiytiWLkaxBiLKuXHGLkaxBiIqWN/vYhRrIGL2BItdjGINRKzYluTcMQcPi1HsYhRrIGIWo9jFKE5F7xW7GMWZ5L1iF6JYPINiF6G4EL1X7CKUbCTvlbgAJUr0XokLUAKi90pcgJJI9F6JC1ASi94rIbFBInqvxAUoSUXvlbgAJZnkvRIXoCQXvVfiIpQUovdKXITSjei9UheiVIneK3UhSkH0XqkLURqJ3it1IUpj0XulLkRpInqvlERwGoc4ZhY+dRFKxSAudRFKxS2UugClYiCXuvhkGoSY9bCZi0+mQYhZD5u5+GTGx7EeNnPxySLJNDMXnsy4uJwV6cKTGRfHuuLMhSfTICQbDsiMxNgahYR1xZkLUKZhSNiUInMRygopRclchHINQ8KGu7mLUK5hSNgMJHcRyjUMCYt67iKUR+LZkrsQ5RqHhLWP3IUoNxkQax+5C1FuIGJhz12IcgMR62dykglpHFLWz+QuRLkGImVhz12MCg1Eyq5S4WJUaCBS1s8ULkYFSN6jcCEqNA4pe2YULkSFmA8VLkKFhiFl7aNwESpSyXUVLkBFJrmuwsWnELOhguSqhZSEFjRb3chZ6IYkrBsl56EbkrJuNBApnwxuSNK6MSixRm9/w201Gil7vNrfcFsDFWv49jfc1oDFBp/2N9w2E4Mw+xtuq4HJhPUlKeymEI95+xtqa8iEjPWmakQ0KOkoUZRpMHxCxhMIlGswjAIfEynKNhhSIWP9r6KEg6EV+AhKUcrBEAsZz05Q0sFQCxlvkpR2MOxCxpskZR4MwZCxnlgR8kGBnDcpQj8owzJk7HGtgDJEIGYvinAQyjANOW/qhIVQhmvIWT+vCA+hDNuQ8yZJmAhl+IactzPCRSjDOOS87RA2QhnSIeftgRASytAOOW8PhJJQhnjIeXsgpIQy1EPO2wOhJZQhH3Ie44hyexqbgseNUBPKEBBs9qcIN6EMA1HwEBN2QhkOgs8VFeEnlGEhCt4cCEOhDA/BZ5aKcBTKMBGFwHES2AwXweehivAUyrARBW9mhKlQho/gs1ZFuAplGImCN8mYkrKxmOMqwlcow0oUvPkSxkLFckasCGehLGnBmzqhLZRhJwre1AlzoQw/UfCmTrgLZcmLDW/rhL9QhqVQG96CCYWhDFGhNrxZEhZDGa5CbXhbI0SGMnSF2vAGlFBS3bDqG4FWJ+gZ0kJteKgJo6EMcaE2PH6E1VCGu1AbHkBCbKjEBpU8goTbUKmNK3kECb2hUnsVwkdJhOFQhsdQikeQkBzKUBl8IqsIzaEMmaGE2xPCdCjDZwhxaErvRQx+ircMwncoQ2vwWZAilIcyzAabBylCeqhUvh8htIcy5AZ/50J4D5VZ4HgzJtSHyixwvBkT9kMZkkMp3owJA6IMzyEE5IQDUYbpEAJywoKoLPXYZUbvtMzGU/xeIlyIMowHnxUrwoYoS4fwhzkhRJShPZRwQhNOROWefI6wIiq3d5C8kyXEiDL0B3+5SJgRZfgPBfxuJuSIMhSIEs5dwo8ow4Io4HcdoUiUIUIU8IZMWBJluBClEypuGAQ9Q4cIa0HAKyx4vM0TskQVFjze3AhfogqQTYhQJsoQI4rnpRVhTZSlTSLewRLmRBl+REW8DRHyRBmOREW8YRACRRmeREW86yYkijJciYp4wyBEiirkCxdFuBTYiFcuQKgUsFRKxN+wEi4FDF+i+Bs8IGQKbCJxUwMhU2Bj0WMNDgibAhuLHmtwQOgUMJQJzyQCoVPA0inSWpDrZsOZ8BccQPgUMJyJ4u8egRAqYOs2+OtHIIwKGNpEmB6hVMBWbwjTI5wK2AIO/moTCKkChjjh2U0gpArYMg6OEQTCqYCt4+A8FhBKBWwhB29shFIBQ5uomK8pIpwKKPnMA1rQYSs6YnbzA63psEUdMbv5YVTXYaDjr4CAlnaAhS7lXCHQ6g6wdDN7iQy0wMOQJypmWSOgNR6Qymck0DIPQ5+omPX1QCs9DH+i+GAaaLWHIVBUwoZOQNgVMAyK4u+GgNArYCgUlUTrKH2TA5DGBMEIPKAQggWiyAMKYVjAMiwCKIRjgcgTuAAhWSBKPaAQlgUMkyKBQmgWiHIPKIRngcgiyO8UQrRAbBHkdwphWiC2CPLnGaFawNApir8SA8K1gOFTFH8rBoRsAUOoqIQ/HgjbAnEiR0VA6BYwlAqfHAKhW8BQKvwlBRC6BQylolL+jCJ8C9hSET40A0K4gCVc+As9IIQLGE6FTTuB0C1g6RZhsxK6BSzdkvJugNAtYOkWPlEGQreApVtS3pYJ3QKWbkkTXjKBz9It0gQJfpZuESoFCd0Clm7hr9CA0C2QilWnQMgWMHyKEDUQrgUs18JnOkC4FkgtfLz7JGQLpOJ9KxCqBVILHr+pCdcClmtJ+U1NuBZIbR0qv0UI2QKGUVE8cwCEboG08JgFIVzAsCqKv8wDQrlAT7mwkRFhXMAyLvx1HhDGBSzjImBNGBewjIuANaFcIEtErAnjApZx4S8KgTAuYBkX/vYPCOMCWe7BmlAuYCkXAWvCuYDlXASsCecClnPhbyGBkC5gSRf+GhII6QKGWeHLPICwLmBZF2nIBD7LuvAXnEBYF7CsC39rCYR1Acu68FeRQFgXsKyL4PAJ6wKWdRF8OOFdwPIu/C0nEN4FCl/4SXgXsLyL4PAJ8QKWeOEvUIEQL2CJF/4GFQjxApZ44a9QgRAvUMjpX0+7mAdXPlf6jVYf7AMs9/fnp3j+WP3aP9WiR2dk6gdc9Jje/vHnn5fnWPT/aenn94MN34c/P0GMRCUJEhVvpkQ9DK8aO7+MCsvKsCyYkqW/EP6sX6OGRaRYhBJElKf91n2tPhJxEWC6r1dZIYuph9diXwRsLgKk5Ti/MxKpjfHIIbKqdSYkiDAvI0b9AY0bbG9d+2P/yPs/NNFk/1CZR/DD/lAZYY6CHGkopKXV3e2TmqhrhhZVn8h2COK69q/vQgLSDYY1l/r1doq75glel6meZfPoYBlfOku7xLM58hjrlhZ8e5CNMUGoZuLgiYDWfPQRrx4aRioJMW93xvaIfQRIljz8v7MHcc9osLwEhj+y/o+06P/IN8Mfcf+HaF7Oo7jYo2EDycWlxst0KrsnLAMttbTp3P5Nfaqa7ov9OCyWFCGbi4LGQiGLEGSRiPvwPlaMWo5RSwYvIhovenEbsnpkt2lqZRSDTzlv30TG6PyhyNZ+KPIiOkW2UQzeKfWsUVsfnLWNEUxxby555O9PVzdG+GSyZY8PuwwtjA56PT1/d3riLZHLGvvXkuCti4/EdHDemYin+db1+TsGSNAGn2sydP2ne3ZlV9kXVCIRERZRJJKI17arX+w3VrBTwOqFrqNOeBvo+xShW/VQvh66g/4qMN3UuXMsioqtBB1QPJUNiSky7D7FY3NXHUqnG+Cx93tmcH1ZD6Su8pTEnb8sefnqKFoZZz2zACn2I6JYAp5WJq6tG9toDhb5l8FdR9IGHL5QzlpkhE1CknB5HwD29jieKKT9VDVN3Tj7Hg1enLH5OD073g0er6RUh06Oa2e8AZq4NG394e/hzakPTf3CDijDA5IM86H/nB5ahgItg7QlbDf9aeaR90RHjOiIHvqvQyHPj84UodNj1cmREJpsLg2aCtBHtGO/CTKcTFqxx6rrl7s87jAQ7urjcDiRzuinsjEWoSNa6lAB4TCESalkV1qQWVP2XMKnvrg6ZxGVfVE39s74YIukuPwsQDf9rF8dczLv/sEjcbye5JfOgvRb9UZeP8WRmOgYzjK4TDLFw0gm58MCnOFhiGHCWcb5BcB4WbGIyCPiufryMry6A/s53L/wrIR+R4x5rcWpbNrKvlME7VjkcOI+JtTF55K41hyl2m6d6eTY33hmY7vrw9TpXeDeHuXHWlCPN1wkm9YggA6gwP5bPLHOL2jDhx7q2B95Rf9flQ9HeT5kMyod8pvheMyGOLyQPF+vdZw447QmHRInMRN8qmtnyhFCTN7Vdf1cnvaOm0QzljcxE5cgiPqQR/XLEvf/P6QPRTYE/+K4uu4EzmzQqKJ+kVPR2XXdaXh3i8Ni4LAnH3KZdEhOM8ku3BRbG6ezYEhqLp2JezZ9dMTg9ZNsZW8iFJZBS9Hxlkvr2n+9lTN0wDtcjKv2L1XzWO3Eoxo7XyVG7Xu6P3GqozYiDsft4XXHxSXKocBSUa8R4KKHdlmWDnYpjuCkv+vXJ7lk4+giZTQG0RLYA0dhBydGJ9S5axIbWfRApSSDaRfSQhz2bVc34/BQAfZ3ohny6RZOEUGa/qF2wnnMfIqpzPnbYNgv46gF5J72vdQ4dsOW1vujs/senLUYig2HrRtxYNIrGTx/LnlqavyYRs8lxHSnUbQEOBMUmS/d9aE+7Krm4fUwhg1bLUiIC+kx3rbKN9/98ZGhy3UlKXI6PuWtnYETQ+N8tIdwMH39rKNXGE1RFApRoA/Ik94+VDRguhHtQkvtA35njGhfR724pBjGKB1ggzQ+NIyQzHgYosjSvlByF+cLfe94GNFmOJmzIcYppKNkREtgYwDRjutj9fveWfkY+Y1YQq0+apdVuaEt2srijZE5bM8u21lGhLh4W8QYbeZ4EMlmhy+YojMO9TsHH5shYBTZICuoPDii0LYpBgsQI8PzR3ZwdoKtQFz14YMQ2Ndhv5tIBqydzJi3ws5iMDjJbDnSA3PrsDlfaw2hsZJsoJc1hkThIFnXVnv7/7bvnjgZzoYSV0THo23HTKvAyVEsbTfK4aFOw+btbSru12O4YikGlyjmsXwmjh1iKpn5qam35qszGGcMdDogLVLmp6bu6m3tGDgm6/rZ9P8VDwm8zanPw+x11Cdt57B/I+0b89EBF2qcRfp6mY1TdSTGTpH9ihy66d/2nzrAeGAzE1Ofpip3fXQ2NjQcY4oXqVSClwfDpitSLVpi3XjpYBx1JtI2tHJkjta5ZpAXqP/SHnaGONMe+HoQb++a4XWkpX1XKT5bsXcUIR5eh26+YIJPUOzfxCSgMV+iZv0j3rIbGQ7dn+iO0BJE/c44b12PqHEaio1sM0QR6RBYx9L27UVxQSI+50FJTqwXwK0LjjBA3Li9AI7Lw5eGIJJn3BbBXlRtzqsgYlvXblQaYZdTiN1ej/qigCak+L4UxPC8LT/7qnzA2Rx9BDtYRiTBqYXuqq7cH6ods6KAEekd8lAkoMRLby2UFhHRWhhw9lAvecjrRevjJNMTEafG0EtMBkY1lpyWlrw/nl47abxO7thLHbaNGNVSqaOxYuR7acnAVoqVWvZzqzi/xNaXD9Y7TF4/IyEL4mkOHDuLSbb9pN3+VA6ftMPHILYc8SaurcYBDbY5JeYnuie9zs3wMohRpul5vnN1p43zZJFmbKtuks7HtS4KfJI4ig9n2yJV2VbCdTqm9kA6EtpKukrHB4Oa6M5k+7j+QinP4IUEv8Dweyy3k1J5fDorsZYKCeCz9wyfCCJxZcS4QSwupFObc1DvmQkbJWEbSDy2zIYJ+F5MiUdxW3UTh0qB5YiBVi/Hc44UTkTuMaqQo6PAu1Q8ogVh1N0UeLfEHpCmDogCm52YqTOCRiNyrrJEwxtdQ+GgUmSE2+f9iVC7rtOz5iofwLoolhSp4PGKCaitwGMtHSOQiP1bNwbHVQIwsIoghyT2G8JszVSCV04OEPrPgeGZYxeRDen9UIUHw7UaiIS5lUlLTxQ+x0Asghl1w2krDLEUiHdMo3XAtQ6qGOrYxD3BBeA4PVHD/SuIZEl3aLflc/WFHmGYbh44XfGupzu0z9WonhkH5FEfEYl3PfSmAC2kNHvicDHddl664SIaUskAXtuqkavc8WWqKiTT/my/Z4RGj3DMB9JNrL/8rdyT8lS8HYbQHPgM4pf16rQ/VYf9sVq9vf/lzz//H3NpFEoH6wAA"; \ No newline at end of file diff --git a/assets/style.css b/assets/style.css new file mode 100644 index 00000000..07a385b7 --- /dev/null +++ b/assets/style.css @@ -0,0 +1,1394 @@ +:root { + /* Light */ + --light-color-background: #f2f4f8; + --light-color-background-secondary: #eff0f1; + --light-color-warning-text: #222; + --light-color-background-warning: #e6e600; + --light-color-icon-background: var(--light-color-background); + --light-color-accent: #c5c7c9; + --light-color-active-menu-item: var(--light-color-accent); + --light-color-text: #222; + --light-color-text-aside: #6e6e6e; + --light-color-link: #1f70c2; + + --light-color-ts-keyword: #056bd6; + --light-color-ts-project: #b111c9; + --light-color-ts-module: var(--light-color-ts-project); + --light-color-ts-namespace: var(--light-color-ts-project); + --light-color-ts-enum: #7e6f15; + --light-color-ts-enum-member: var(--light-color-ts-enum); + --light-color-ts-variable: #4760ec; + --light-color-ts-function: #572be7; + --light-color-ts-class: #1f70c2; + --light-color-ts-interface: #108024; + --light-color-ts-constructor: var(--light-color-ts-class); + --light-color-ts-property: var(--light-color-ts-variable); + --light-color-ts-method: var(--light-color-ts-function); + --light-color-ts-call-signature: var(--light-color-ts-method); + --light-color-ts-index-signature: var(--light-color-ts-property); + --light-color-ts-constructor-signature: var(--light-color-ts-constructor); + --light-color-ts-parameter: var(--light-color-ts-variable); + /* type literal not included as links will never be generated to it */ + --light-color-ts-type-parameter: var(--light-color-ts-type-alias); + --light-color-ts-accessor: var(--light-color-ts-property); + --light-color-ts-get-signature: var(--light-color-ts-accessor); + --light-color-ts-set-signature: var(--light-color-ts-accessor); + --light-color-ts-type-alias: #d51270; + /* reference not included as links will be colored with the kind that it points to */ + + --light-external-icon: url("data:image/svg+xml;utf8,"); + --light-color-scheme: light; + + /* Dark */ + --dark-color-background: #2b2e33; + --dark-color-background-secondary: #1e2024; + --dark-color-background-warning: #bebe00; + --dark-color-warning-text: #222; + --dark-color-icon-background: var(--dark-color-background-secondary); + --dark-color-accent: #9096a2; + --dark-color-active-menu-item: #5d5d6a; + --dark-color-text: #f5f5f5; + --dark-color-text-aside: #dddddd; + --dark-color-link: #00aff4; + + --dark-color-ts-keyword: #3399ff; + --dark-color-ts-project: #e358ff; + --dark-color-ts-module: var(--dark-color-ts-project); + --dark-color-ts-namespace: var(--dark-color-ts-project); + --dark-color-ts-enum: #f4d93e; + --dark-color-ts-enum-member: var(--dark-color-ts-enum); + --dark-color-ts-variable: #798dff; + --dark-color-ts-function: #a280ff; + --dark-color-ts-class: #8ac4ff; + --dark-color-ts-interface: #6cff87; + --dark-color-ts-constructor: var(--dark-color-ts-class); + --dark-color-ts-property: var(--dark-color-ts-variable); + --dark-color-ts-method: var(--dark-color-ts-function); + --dark-color-ts-call-signature: var(--dark-color-ts-method); + --dark-color-ts-index-signature: var(--dark-color-ts-property); + --dark-color-ts-constructor-signature: var(--dark-color-ts-constructor); + --dark-color-ts-parameter: var(--dark-color-ts-variable); + /* type literal not included as links will never be generated to it */ + --dark-color-ts-type-parameter: var(--dark-color-ts-type-alias); + --dark-color-ts-accessor: var(--dark-color-ts-property); + --dark-color-ts-get-signature: var(--dark-color-ts-accessor); + --dark-color-ts-set-signature: var(--dark-color-ts-accessor); + --dark-color-ts-type-alias: #ff6492; + /* reference not included as links will be colored with the kind that it points to */ + + --dark-external-icon: url("data:image/svg+xml;utf8,"); + --dark-color-scheme: dark; +} + +@media (prefers-color-scheme: light) { + :root { + --color-background: var(--light-color-background); + --color-background-secondary: var(--light-color-background-secondary); + --color-background-warning: var(--light-color-background-warning); + --color-warning-text: var(--light-color-warning-text); + --color-icon-background: var(--light-color-icon-background); + --color-accent: var(--light-color-accent); + --color-active-menu-item: var(--light-color-active-menu-item); + --color-text: var(--light-color-text); + --color-text-aside: var(--light-color-text-aside); + --color-link: var(--light-color-link); + + --color-ts-keyword: var(--light-color-ts-keyword); + --color-ts-module: var(--light-color-ts-module); + --color-ts-namespace: var(--light-color-ts-namespace); + --color-ts-enum: var(--light-color-ts-enum); + --color-ts-enum-member: var(--light-color-ts-enum-member); + --color-ts-variable: var(--light-color-ts-variable); + --color-ts-function: var(--light-color-ts-function); + --color-ts-class: var(--light-color-ts-class); + --color-ts-interface: var(--light-color-ts-interface); + --color-ts-constructor: var(--light-color-ts-constructor); + --color-ts-property: var(--light-color-ts-property); + --color-ts-method: var(--light-color-ts-method); + --color-ts-call-signature: var(--light-color-ts-call-signature); + --color-ts-index-signature: var(--light-color-ts-index-signature); + --color-ts-constructor-signature: var( + --light-color-ts-constructor-signature + ); + --color-ts-parameter: var(--light-color-ts-parameter); + --color-ts-type-parameter: var(--light-color-ts-type-parameter); + --color-ts-accessor: var(--light-color-ts-accessor); + --color-ts-get-signature: var(--light-color-ts-get-signature); + --color-ts-set-signature: var(--light-color-ts-set-signature); + --color-ts-type-alias: var(--light-color-ts-type-alias); + + --external-icon: var(--light-external-icon); + --color-scheme: var(--light-color-scheme); + } +} + +@media (prefers-color-scheme: dark) { + :root { + --color-background: var(--dark-color-background); + --color-background-secondary: var(--dark-color-background-secondary); + --color-background-warning: var(--dark-color-background-warning); + --color-warning-text: var(--dark-color-warning-text); + --color-icon-background: var(--dark-color-icon-background); + --color-accent: var(--dark-color-accent); + --color-active-menu-item: var(--dark-color-active-menu-item); + --color-text: var(--dark-color-text); + --color-text-aside: var(--dark-color-text-aside); + --color-link: var(--dark-color-link); + + --color-ts-keyword: var(--dark-color-ts-keyword); + --color-ts-module: var(--dark-color-ts-module); + --color-ts-namespace: var(--dark-color-ts-namespace); + --color-ts-enum: var(--dark-color-ts-enum); + --color-ts-enum-member: var(--dark-color-ts-enum-member); + --color-ts-variable: var(--dark-color-ts-variable); + --color-ts-function: var(--dark-color-ts-function); + --color-ts-class: var(--dark-color-ts-class); + --color-ts-interface: var(--dark-color-ts-interface); + --color-ts-constructor: var(--dark-color-ts-constructor); + --color-ts-property: var(--dark-color-ts-property); + --color-ts-method: var(--dark-color-ts-method); + --color-ts-call-signature: var(--dark-color-ts-call-signature); + --color-ts-index-signature: var(--dark-color-ts-index-signature); + --color-ts-constructor-signature: var( + --dark-color-ts-constructor-signature + ); + --color-ts-parameter: var(--dark-color-ts-parameter); + --color-ts-type-parameter: var(--dark-color-ts-type-parameter); + --color-ts-accessor: var(--dark-color-ts-accessor); + --color-ts-get-signature: var(--dark-color-ts-get-signature); + --color-ts-set-signature: var(--dark-color-ts-set-signature); + --color-ts-type-alias: var(--dark-color-ts-type-alias); + + --external-icon: var(--dark-external-icon); + --color-scheme: var(--dark-color-scheme); + } +} + +html { + color-scheme: var(--color-scheme); +} + +body { + margin: 0; +} + +:root[data-theme="light"] { + --color-background: var(--light-color-background); + --color-background-secondary: var(--light-color-background-secondary); + --color-background-warning: var(--light-color-background-warning); + --color-warning-text: var(--light-color-warning-text); + --color-icon-background: var(--light-color-icon-background); + --color-accent: var(--light-color-accent); + --color-active-menu-item: var(--light-color-active-menu-item); + --color-text: var(--light-color-text); + --color-text-aside: var(--light-color-text-aside); + --color-link: var(--light-color-link); + + --color-ts-keyword: var(--light-color-ts-keyword); + --color-ts-module: var(--light-color-ts-module); + --color-ts-namespace: var(--light-color-ts-namespace); + --color-ts-enum: var(--light-color-ts-enum); + --color-ts-enum-member: var(--light-color-ts-enum-member); + --color-ts-variable: var(--light-color-ts-variable); + --color-ts-function: var(--light-color-ts-function); + --color-ts-class: var(--light-color-ts-class); + --color-ts-interface: var(--light-color-ts-interface); + --color-ts-constructor: var(--light-color-ts-constructor); + --color-ts-property: var(--light-color-ts-property); + --color-ts-method: var(--light-color-ts-method); + --color-ts-call-signature: var(--light-color-ts-call-signature); + --color-ts-index-signature: var(--light-color-ts-index-signature); + --color-ts-constructor-signature: var( + --light-color-ts-constructor-signature + ); + --color-ts-parameter: var(--light-color-ts-parameter); + --color-ts-type-parameter: var(--light-color-ts-type-parameter); + --color-ts-accessor: var(--light-color-ts-accessor); + --color-ts-get-signature: var(--light-color-ts-get-signature); + --color-ts-set-signature: var(--light-color-ts-set-signature); + --color-ts-type-alias: var(--light-color-ts-type-alias); + + --external-icon: var(--light-external-icon); + --color-scheme: var(--light-color-scheme); +} + +:root[data-theme="dark"] { + --color-background: var(--dark-color-background); + --color-background-secondary: var(--dark-color-background-secondary); + --color-background-warning: var(--dark-color-background-warning); + --color-warning-text: var(--dark-color-warning-text); + --color-icon-background: var(--dark-color-icon-background); + --color-accent: var(--dark-color-accent); + --color-active-menu-item: var(--dark-color-active-menu-item); + --color-text: var(--dark-color-text); + --color-text-aside: var(--dark-color-text-aside); + --color-link: var(--dark-color-link); + + --color-ts-keyword: var(--dark-color-ts-keyword); + --color-ts-module: var(--dark-color-ts-module); + --color-ts-namespace: var(--dark-color-ts-namespace); + --color-ts-enum: var(--dark-color-ts-enum); + --color-ts-enum-member: var(--dark-color-ts-enum-member); + --color-ts-variable: var(--dark-color-ts-variable); + --color-ts-function: var(--dark-color-ts-function); + --color-ts-class: var(--dark-color-ts-class); + --color-ts-interface: var(--dark-color-ts-interface); + --color-ts-constructor: var(--dark-color-ts-constructor); + --color-ts-property: var(--dark-color-ts-property); + --color-ts-method: var(--dark-color-ts-method); + --color-ts-call-signature: var(--dark-color-ts-call-signature); + --color-ts-index-signature: var(--dark-color-ts-index-signature); + --color-ts-constructor-signature: var( + --dark-color-ts-constructor-signature + ); + --color-ts-parameter: var(--dark-color-ts-parameter); + --color-ts-type-parameter: var(--dark-color-ts-type-parameter); + --color-ts-accessor: var(--dark-color-ts-accessor); + --color-ts-get-signature: var(--dark-color-ts-get-signature); + --color-ts-set-signature: var(--dark-color-ts-set-signature); + --color-ts-type-alias: var(--dark-color-ts-type-alias); + + --external-icon: var(--dark-external-icon); + --color-scheme: var(--dark-color-scheme); +} + +.always-visible, +.always-visible .tsd-signatures { + display: inherit !important; +} + +h1, +h2, +h3, +h4, +h5, +h6 { + line-height: 1.2; +} + +h1 > a, +h2 > a, +h3 > a, +h4 > a, +h5 > a, +h6 > a { + text-decoration: none; + color: var(--color-text); +} + +h1 { + font-size: 1.875rem; + margin: 0.67rem 0; +} + +h2 { + font-size: 1.5rem; + margin: 0.83rem 0; +} + +h3 { + font-size: 1.25rem; + margin: 1rem 0; +} + +h4 { + font-size: 1.05rem; + margin: 1.33rem 0; +} + +h5 { + font-size: 1rem; + margin: 1.5rem 0; +} + +h6 { + font-size: 0.875rem; + margin: 2.33rem 0; +} + +.uppercase { + text-transform: uppercase; +} + +dl, +menu, +ol, +ul { + margin: 1em 0; +} + +dd { + margin: 0 0 0 40px; +} + +.container { + max-width: 1700px; + padding: 0 2rem; +} + +/* Footer */ +.tsd-generator { + border-top: 1px solid var(--color-accent); + padding-top: 1rem; + padding-bottom: 1rem; + max-height: 3.5rem; +} + +.tsd-generator > p { + margin-top: 0; + margin-bottom: 0; + padding: 0 1rem; +} + +.container-main { + margin: 0 auto; + /* toolbar, footer, margin */ + min-height: calc(100vh - 41px - 56px - 4rem); +} + +@keyframes fade-in { + from { + opacity: 0; + } + to { + opacity: 1; + } +} +@keyframes fade-out { + from { + opacity: 1; + visibility: visible; + } + to { + opacity: 0; + } +} +@keyframes fade-in-delayed { + 0% { + opacity: 0; + } + 33% { + opacity: 0; + } + 100% { + opacity: 1; + } +} +@keyframes fade-out-delayed { + 0% { + opacity: 1; + visibility: visible; + } + 66% { + opacity: 0; + } + 100% { + opacity: 0; + } +} +@keyframes pop-in-from-right { + from { + transform: translate(100%, 0); + } + to { + transform: translate(0, 0); + } +} +@keyframes pop-out-to-right { + from { + transform: translate(0, 0); + visibility: visible; + } + to { + transform: translate(100%, 0); + } +} +body { + background: var(--color-background); + font-family: "Segoe UI", sans-serif; + font-size: 16px; + color: var(--color-text); +} + +a { + color: var(--color-link); + text-decoration: none; +} +a:hover { + text-decoration: underline; +} +a.external[target="_blank"] { + background-image: var(--external-icon); + background-position: top 3px right; + background-repeat: no-repeat; + padding-right: 13px; +} + +code, +pre { + font-family: Menlo, Monaco, Consolas, "Courier New", monospace; + padding: 0.2em; + margin: 0; + font-size: 0.875rem; + border-radius: 0.8em; +} + +pre { + position: relative; + white-space: pre; + white-space: pre-wrap; + word-wrap: break-word; + padding: 10px; + border: 1px solid var(--color-accent); +} +pre code { + padding: 0; + font-size: 100%; +} +pre > button { + position: absolute; + top: 10px; + right: 10px; + opacity: 0; + transition: opacity 0.1s; + box-sizing: border-box; +} +pre:hover > button, +pre > button.visible { + opacity: 1; +} + +blockquote { + margin: 1em 0; + padding-left: 1em; + border-left: 4px solid gray; +} + +.tsd-typography { + line-height: 1.333em; +} +.tsd-typography ul { + list-style: square; + padding: 0 0 0 20px; + margin: 0; +} +.tsd-typography .tsd-index-panel h3, +.tsd-index-panel .tsd-typography h3, +.tsd-typography h4, +.tsd-typography h5, +.tsd-typography h6 { + font-size: 1em; +} +.tsd-typography h5, +.tsd-typography h6 { + font-weight: normal; +} +.tsd-typography p, +.tsd-typography ul, +.tsd-typography ol { + margin: 1em 0; +} +.tsd-typography table { + border-collapse: collapse; + border: none; +} +.tsd-typography td, +.tsd-typography th { + padding: 6px 13px; + border: 1px solid var(--color-accent); +} +.tsd-typography thead, +.tsd-typography tr:nth-child(even) { + background-color: var(--color-background-secondary); +} + +.tsd-breadcrumb { + margin: 0; + padding: 0; + color: var(--color-text-aside); +} +.tsd-breadcrumb a { + color: var(--color-text-aside); + text-decoration: none; +} +.tsd-breadcrumb a:hover { + text-decoration: underline; +} +.tsd-breadcrumb li { + display: inline; +} +.tsd-breadcrumb li:after { + content: " / "; +} + +.tsd-comment-tags { + display: flex; + flex-direction: column; +} +dl.tsd-comment-tag-group { + display: flex; + align-items: center; + overflow: hidden; + margin: 0.5em 0; +} +dl.tsd-comment-tag-group dt { + display: flex; + margin-right: 0.5em; + font-size: 0.875em; + font-weight: normal; +} +dl.tsd-comment-tag-group dd { + margin: 0; +} +code.tsd-tag { + padding: 0.25em 0.4em; + border: 0.1em solid var(--color-accent); + margin-right: 0.25em; + font-size: 70%; +} +h1 code.tsd-tag:first-of-type { + margin-left: 0.25em; +} + +dl.tsd-comment-tag-group dd:before, +dl.tsd-comment-tag-group dd:after { + content: " "; +} +dl.tsd-comment-tag-group dd pre, +dl.tsd-comment-tag-group dd:after { + clear: both; +} +dl.tsd-comment-tag-group p { + margin: 0; +} + +.tsd-panel.tsd-comment .lead { + font-size: 1.1em; + line-height: 1.333em; + margin-bottom: 2em; +} +.tsd-panel.tsd-comment .lead:last-child { + margin-bottom: 0; +} + +.tsd-filter-visibility h4 { + font-size: 1rem; + padding-top: 0.75rem; + padding-bottom: 0.5rem; + margin: 0; +} +.tsd-filter-item:not(:last-child) { + margin-bottom: 0.5rem; +} +.tsd-filter-input { + display: flex; + width: fit-content; + width: -moz-fit-content; + align-items: center; + user-select: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + cursor: pointer; +} +.tsd-filter-input input[type="checkbox"] { + cursor: pointer; + position: absolute; + width: 1.5em; + height: 1.5em; + opacity: 0; +} +.tsd-filter-input input[type="checkbox"]:disabled { + pointer-events: none; +} +.tsd-filter-input svg { + cursor: pointer; + width: 1.5em; + height: 1.5em; + margin-right: 0.5em; + border-radius: 0.33em; + /* Leaving this at full opacity breaks event listeners on Firefox. + Don't remove unless you know what you're doing. */ + opacity: 0.99; +} +.tsd-filter-input input[type="checkbox"]:focus + svg { + transform: scale(0.95); +} +.tsd-filter-input input[type="checkbox"]:focus:not(:focus-visible) + svg { + transform: scale(1); +} +.tsd-checkbox-background { + fill: var(--color-accent); +} +input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { + stroke: var(--color-text); +} +.tsd-filter-input input:disabled ~ svg > .tsd-checkbox-background { + fill: var(--color-background); + stroke: var(--color-accent); + stroke-width: 0.25rem; +} +.tsd-filter-input input:disabled ~ svg > .tsd-checkbox-checkmark { + stroke: var(--color-accent); +} + +.tsd-theme-toggle { + padding-top: 0.75rem; +} +.tsd-theme-toggle > h4 { + display: inline; + vertical-align: middle; + margin-right: 0.75rem; +} + +.tsd-hierarchy { + list-style: square; + margin: 0; +} +.tsd-hierarchy .target { + font-weight: bold; +} + +.tsd-panel-group.tsd-index-group { + margin-bottom: 0; +} +.tsd-index-panel .tsd-index-list { + list-style: none; + line-height: 1.333em; + margin: 0; + padding: 0.25rem 0 0 0; + overflow: hidden; + display: grid; + grid-template-columns: repeat(3, 1fr); + column-gap: 1rem; + grid-template-rows: auto; +} +@media (max-width: 1024px) { + .tsd-index-panel .tsd-index-list { + grid-template-columns: repeat(2, 1fr); + } +} +@media (max-width: 768px) { + .tsd-index-panel .tsd-index-list { + grid-template-columns: repeat(1, 1fr); + } +} +.tsd-index-panel .tsd-index-list li { + -webkit-page-break-inside: avoid; + -moz-page-break-inside: avoid; + -ms-page-break-inside: avoid; + -o-page-break-inside: avoid; + page-break-inside: avoid; +} + +.tsd-flag { + display: inline-block; + padding: 0.25em 0.4em; + border-radius: 4px; + color: var(--color-comment-tag-text); + background-color: var(--color-comment-tag); + text-indent: 0; + font-size: 75%; + line-height: 1; + font-weight: normal; +} + +.tsd-anchor { + position: relative; + top: -100px; +} + +.tsd-member { + position: relative; +} +.tsd-member .tsd-anchor + h3 { + display: flex; + align-items: center; + margin-top: 0; + margin-bottom: 0; + border-bottom: none; +} + +.tsd-navigation.settings { + margin: 1rem 0; +} +.tsd-navigation > a, +.tsd-navigation .tsd-accordion-summary { + width: calc(100% - 0.5rem); +} +.tsd-navigation a, +.tsd-navigation summary > span, +.tsd-page-navigation a { + display: inline-flex; + align-items: center; + padding: 0.25rem; + color: var(--color-text); + text-decoration: none; + box-sizing: border-box; +} +.tsd-navigation a.current, +.tsd-page-navigation a.current { + background: var(--color-active-menu-item); +} +.tsd-navigation a:hover, +.tsd-page-navigation a:hover { + text-decoration: underline; +} +.tsd-navigation ul, +.tsd-page-navigation ul { + margin-top: 0; + margin-bottom: 0; + padding: 0; + list-style: none; +} +.tsd-navigation li, +.tsd-page-navigation li { + padding: 0; + max-width: 100%; +} +.tsd-nested-navigation { + margin-left: 3rem; +} +.tsd-nested-navigation > li > details { + margin-left: -1.5rem; +} +.tsd-small-nested-navigation { + margin-left: 1.5rem; +} +.tsd-small-nested-navigation > li > details { + margin-left: -1.5rem; +} + +.tsd-nested-navigation > li > a, +.tsd-nested-navigation > li > span { + width: calc(100% - 1.75rem - 0.5rem); +} + +.tsd-page-navigation ul { + padding-left: 1.75rem; +} + +#tsd-sidebar-links a { + margin-top: 0; + margin-bottom: 0.5rem; + line-height: 1.25rem; +} +#tsd-sidebar-links a:last-of-type { + margin-bottom: 0; +} + +a.tsd-index-link { + padding: 0.25rem 0 !important; + font-size: 1rem; + line-height: 1.25rem; + display: inline-flex; + align-items: center; + color: var(--color-text); +} +.tsd-accordion-summary { + list-style-type: none; /* hide marker on non-safari */ + outline: none; /* broken on safari, so just hide it */ +} +.tsd-accordion-summary::-webkit-details-marker { + display: none; /* hide marker on safari */ +} +.tsd-accordion-summary, +.tsd-accordion-summary a { + user-select: none; + -moz-user-select: none; + -webkit-user-select: none; + -ms-user-select: none; + + cursor: pointer; +} +.tsd-accordion-summary a { + width: calc(100% - 1.5rem); +} +.tsd-accordion-summary > * { + margin-top: 0; + margin-bottom: 0; + padding-top: 0; + padding-bottom: 0; +} +.tsd-index-accordion .tsd-accordion-summary > svg { + margin-left: 0.25rem; +} +.tsd-index-content > :not(:first-child) { + margin-top: 0.75rem; +} +.tsd-index-heading { + margin-top: 1.5rem; + margin-bottom: 0.75rem; +} + +.tsd-kind-icon { + margin-right: 0.5rem; + width: 1.25rem; + height: 1.25rem; + min-width: 1.25rem; + min-height: 1.25rem; +} +.tsd-kind-icon path { + transform-origin: center; + transform: scale(1.1); +} +.tsd-signature > .tsd-kind-icon { + margin-right: 0.8rem; +} + +.tsd-panel { + margin-bottom: 2.5rem; +} +.tsd-panel.tsd-member { + margin-bottom: 4rem; +} +.tsd-panel:empty { + display: none; +} +.tsd-panel > h1, +.tsd-panel > h2, +.tsd-panel > h3 { + margin: 1.5rem -1.5rem 0.75rem -1.5rem; + padding: 0 1.5rem 0.75rem 1.5rem; +} +.tsd-panel > h1.tsd-before-signature, +.tsd-panel > h2.tsd-before-signature, +.tsd-panel > h3.tsd-before-signature { + margin-bottom: 0; + border-bottom: none; +} + +.tsd-panel-group { + margin: 4rem 0; +} +.tsd-panel-group.tsd-index-group { + margin: 2rem 0; +} +.tsd-panel-group.tsd-index-group details { + margin: 2rem 0; +} + +#tsd-search { + transition: background-color 0.2s; +} +#tsd-search .title { + position: relative; + z-index: 2; +} +#tsd-search .field { + position: absolute; + left: 0; + top: 0; + right: 2.5rem; + height: 100%; +} +#tsd-search .field input { + box-sizing: border-box; + position: relative; + top: -50px; + z-index: 1; + width: 100%; + padding: 0 10px; + opacity: 0; + outline: 0; + border: 0; + background: transparent; + color: var(--color-text); +} +#tsd-search .field label { + position: absolute; + overflow: hidden; + right: -40px; +} +#tsd-search .field input, +#tsd-search .title, +#tsd-toolbar-links a { + transition: opacity 0.2s; +} +#tsd-search .results { + position: absolute; + visibility: hidden; + top: 40px; + width: 100%; + margin: 0; + padding: 0; + list-style: none; + box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); +} +#tsd-search .results li { + background-color: var(--color-background); + line-height: initial; + padding: 4px; +} +#tsd-search .results li:nth-child(even) { + background-color: var(--color-background-secondary); +} +#tsd-search .results li.state { + display: none; +} +#tsd-search .results li.current:not(.no-results), +#tsd-search .results li:hover:not(.no-results) { + background-color: var(--color-accent); +} +#tsd-search .results a { + display: flex; + align-items: center; + padding: 0.25rem; + box-sizing: border-box; +} +#tsd-search .results a:before { + top: 10px; +} +#tsd-search .results span.parent { + color: var(--color-text-aside); + font-weight: normal; +} +#tsd-search.has-focus { + background-color: var(--color-accent); +} +#tsd-search.has-focus .field input { + top: 0; + opacity: 1; +} +#tsd-search.has-focus .title, +#tsd-search.has-focus #tsd-toolbar-links a { + z-index: 0; + opacity: 0; +} +#tsd-search.has-focus .results { + visibility: visible; +} +#tsd-search.loading .results li.state.loading { + display: block; +} +#tsd-search.failure .results li.state.failure { + display: block; +} + +#tsd-toolbar-links { + position: absolute; + top: 0; + right: 2rem; + height: 100%; + display: flex; + align-items: center; + justify-content: flex-end; +} +#tsd-toolbar-links a { + margin-left: 1.5rem; +} +#tsd-toolbar-links a:hover { + text-decoration: underline; +} + +.tsd-signature { + margin: 0 0 1rem 0; + padding: 1rem 0.5rem; + border: 1px solid var(--color-accent); + font-family: Menlo, Monaco, Consolas, "Courier New", monospace; + font-size: 14px; + overflow-x: auto; +} + +.tsd-signature-keyword { + color: var(--color-ts-keyword); + font-weight: normal; +} + +.tsd-signature-symbol { + color: var(--color-text-aside); + font-weight: normal; +} + +.tsd-signature-type { + font-style: italic; + font-weight: normal; +} + +.tsd-signatures { + padding: 0; + margin: 0 0 1em 0; + list-style-type: none; +} +.tsd-signatures .tsd-signature { + margin: 0; + border-color: var(--color-accent); + border-width: 1px 0; + transition: background-color 0.1s; +} +.tsd-description .tsd-signatures .tsd-signature { + border-width: 1px; +} + +ul.tsd-parameter-list, +ul.tsd-type-parameter-list { + list-style: square; + margin: 0; + padding-left: 20px; +} +ul.tsd-parameter-list > li.tsd-parameter-signature, +ul.tsd-type-parameter-list > li.tsd-parameter-signature { + list-style: none; + margin-left: -20px; +} +ul.tsd-parameter-list h5, +ul.tsd-type-parameter-list h5 { + font-size: 16px; + margin: 1em 0 0.5em 0; +} +.tsd-sources { + margin-top: 1rem; + font-size: 0.875em; +} +.tsd-sources a { + color: var(--color-text-aside); + text-decoration: underline; +} +.tsd-sources ul { + list-style: none; + padding: 0; +} + +.tsd-page-toolbar { + position: sticky; + z-index: 1; + top: 0; + left: 0; + width: 100%; + color: var(--color-text); + background: var(--color-background-secondary); + border-bottom: 1px var(--color-accent) solid; + transition: transform 0.3s ease-in-out; +} +.tsd-page-toolbar a { + color: var(--color-text); + text-decoration: none; +} +.tsd-page-toolbar a.title { + font-weight: bold; +} +.tsd-page-toolbar a.title:hover { + text-decoration: underline; +} +.tsd-page-toolbar .tsd-toolbar-contents { + display: flex; + justify-content: space-between; + height: 2.5rem; + margin: 0 auto; +} +.tsd-page-toolbar .table-cell { + position: relative; + white-space: nowrap; + line-height: 40px; +} +.tsd-page-toolbar .table-cell:first-child { + width: 100%; +} +.tsd-page-toolbar .tsd-toolbar-icon { + box-sizing: border-box; + line-height: 0; + padding: 12px 0; +} + +.tsd-widget { + display: inline-block; + overflow: hidden; + opacity: 0.8; + height: 40px; + transition: + opacity 0.1s, + background-color 0.2s; + vertical-align: bottom; + cursor: pointer; +} +.tsd-widget:hover { + opacity: 0.9; +} +.tsd-widget.active { + opacity: 1; + background-color: var(--color-accent); +} +.tsd-widget.no-caption { + width: 40px; +} +.tsd-widget.no-caption:before { + margin: 0; +} + +.tsd-widget.options, +.tsd-widget.menu { + display: none; +} +input[type="checkbox"] + .tsd-widget:before { + background-position: -120px 0; +} +input[type="checkbox"]:checked + .tsd-widget:before { + background-position: -160px 0; +} + +img { + max-width: 100%; +} + +.tsd-anchor-icon { + display: inline-flex; + align-items: center; + margin-left: 0.5rem; + vertical-align: middle; + color: var(--color-text); +} + +.tsd-anchor-icon svg { + width: 1em; + height: 1em; + visibility: hidden; +} + +.tsd-anchor-link:hover > .tsd-anchor-icon svg { + visibility: visible; +} + +.deprecated { + text-decoration: line-through !important; +} + +.warning { + padding: 1rem; + color: var(--color-warning-text); + background: var(--color-background-warning); +} + +.tsd-kind-project { + color: var(--color-ts-project); +} +.tsd-kind-module { + color: var(--color-ts-module); +} +.tsd-kind-namespace { + color: var(--color-ts-namespace); +} +.tsd-kind-enum { + color: var(--color-ts-enum); +} +.tsd-kind-enum-member { + color: var(--color-ts-enum-member); +} +.tsd-kind-variable { + color: var(--color-ts-variable); +} +.tsd-kind-function { + color: var(--color-ts-function); +} +.tsd-kind-class { + color: var(--color-ts-class); +} +.tsd-kind-interface { + color: var(--color-ts-interface); +} +.tsd-kind-constructor { + color: var(--color-ts-constructor); +} +.tsd-kind-property { + color: var(--color-ts-property); +} +.tsd-kind-method { + color: var(--color-ts-method); +} +.tsd-kind-call-signature { + color: var(--color-ts-call-signature); +} +.tsd-kind-index-signature { + color: var(--color-ts-index-signature); +} +.tsd-kind-constructor-signature { + color: var(--color-ts-constructor-signature); +} +.tsd-kind-parameter { + color: var(--color-ts-parameter); +} +.tsd-kind-type-literal { + color: var(--color-ts-type-literal); +} +.tsd-kind-type-parameter { + color: var(--color-ts-type-parameter); +} +.tsd-kind-accessor { + color: var(--color-ts-accessor); +} +.tsd-kind-get-signature { + color: var(--color-ts-get-signature); +} +.tsd-kind-set-signature { + color: var(--color-ts-set-signature); +} +.tsd-kind-type-alias { + color: var(--color-ts-type-alias); +} + +/* if we have a kind icon, don't color the text by kind */ +.tsd-kind-icon ~ span { + color: var(--color-text); +} + +* { + scrollbar-width: thin; + scrollbar-color: var(--color-accent) var(--color-icon-background); +} + +*::-webkit-scrollbar { + width: 0.75rem; +} + +*::-webkit-scrollbar-track { + background: var(--color-icon-background); +} + +*::-webkit-scrollbar-thumb { + background-color: var(--color-accent); + border-radius: 999rem; + border: 0.25rem solid var(--color-icon-background); +} + +/* mobile */ +@media (max-width: 769px) { + .tsd-widget.options, + .tsd-widget.menu { + display: inline-block; + } + + .container-main { + display: flex; + } + html .col-content { + float: none; + max-width: 100%; + width: 100%; + } + html .col-sidebar { + position: fixed !important; + overflow-y: auto; + -webkit-overflow-scrolling: touch; + z-index: 1024; + top: 0 !important; + bottom: 0 !important; + left: auto !important; + right: 0 !important; + padding: 1.5rem 1.5rem 0 0; + width: 75vw; + visibility: hidden; + background-color: var(--color-background); + transform: translate(100%, 0); + } + html .col-sidebar > *:last-child { + padding-bottom: 20px; + } + html .overlay { + content: ""; + display: block; + position: fixed; + z-index: 1023; + top: 0; + left: 0; + right: 0; + bottom: 0; + background-color: rgba(0, 0, 0, 0.75); + visibility: hidden; + } + + .to-has-menu .overlay { + animation: fade-in 0.4s; + } + + .to-has-menu .col-sidebar { + animation: pop-in-from-right 0.4s; + } + + .from-has-menu .overlay { + animation: fade-out 0.4s; + } + + .from-has-menu .col-sidebar { + animation: pop-out-to-right 0.4s; + } + + .has-menu body { + overflow: hidden; + } + .has-menu .overlay { + visibility: visible; + } + .has-menu .col-sidebar { + visibility: visible; + transform: translate(0, 0); + display: flex; + flex-direction: column; + gap: 1.5rem; + max-height: 100vh; + padding: 1rem 2rem; + } + .has-menu .tsd-navigation { + max-height: 100%; + } +} + +/* one sidebar */ +@media (min-width: 770px) { + .container-main { + display: grid; + grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); + grid-template-areas: "sidebar content"; + margin: 2rem auto; + } + + .col-sidebar { + grid-area: sidebar; + } + .col-content { + grid-area: content; + padding: 0 1rem; + } +} +@media (min-width: 770px) and (max-width: 1399px) { + .col-sidebar { + max-height: calc(100vh - 2rem - 42px); + overflow: auto; + position: sticky; + top: 42px; + padding-top: 1rem; + } + .site-menu { + margin-top: 1rem; + } +} + +/* two sidebars */ +@media (min-width: 1200px) { + .container-main { + grid-template-columns: minmax(0, 1fr) minmax(0, 2.5fr) minmax(0, 20rem); + grid-template-areas: "sidebar content toc"; + } + + .col-sidebar { + display: contents; + } + + .page-menu { + grid-area: toc; + padding-left: 1rem; + } + .site-menu { + grid-area: sidebar; + } + + .site-menu { + margin-top: 1rem 0; + } + + .page-menu, + .site-menu { + max-height: calc(100vh - 2rem - 42px); + overflow: auto; + position: sticky; + top: 42px; + } +} diff --git a/functions/runFromAPI.html b/functions/runFromAPI.html new file mode 100644 index 00000000..99879874 --- /dev/null +++ b/functions/runFromAPI.html @@ -0,0 +1,4 @@ +runFromAPI | @amadeus-it-group/kassette
  • Launch the proxy programmatically.

    +

    Parameters

    • options: APIOptions

      kassette configuration options

      +

    Returns Promise<(() => void)>

    a callback that can be used to shutdown the proxy, calling the onExit callback defined in configuration (if provided).

    +

Generated using TypeDoc

\ No newline at end of file diff --git a/index.html b/index.html new file mode 100644 index 00000000..b4761b7d --- /dev/null +++ b/index.html @@ -0,0 +1,51 @@ +@amadeus-it-group/kassette

@amadeus-it-group/kassette

kassette

npm +codecov

+

+ kassette-logo +
+ kassette is a development server, used mainly for testing, which proxies requests and +
is able to easily manage local mocks.
+
+

+ +

To use it:

+
    +
  • install with npm install @amadeus-it-group/kassette
  • +
  • add this command to your package.json scripts: kassette -c kassette.config.js
  • +
  • and create the configuration file kassette.config.js:
  • +
+
/**
* @return { import("@amadeus-it-group/kassette").ConfigurationSpec }
*/
exports.getConfiguration = () => {
return {
port: 4200,
mocksFolder: './mocks-folder',
remoteURL: 'http://127.0.0.1:3000',
mode: 'local_or_download',

hook: async ({ mock }) => {
if (!mock.request.pathname.startsWith('/api/')) {
mock.setMode('remote');
return;
}

mock.setLocalPath([mock.request.pathname.split('/').slice(1), mock.request.method]);
},
};
}; +
+

Now run your script to launch the proxy!

+

With this configuration, input requests targeting URLs starting with /api/ will get processed, and local mocks will be used if present, otherwise data will be downloaded from http://127.0.0.1:3000 with a forwarded request, persisted and used for future input requests.

+

Note that kassette can also be configured to run as a browser proxy, reading the target URL from the request, and intercepting HTTPS communications.

+

Check Getting started to learn more.

+

Main features

    +
  • optionally forward requests to a remote backend
  • +
  • record backend responses for later use
  • +
  • easily computed and set local mock path
  • +
  • fill response to client from backend response, downloaded or persisted
  • +
  • modify response to client manually
  • +
  • can optionally act as the browser proxy
  • +
  • generate TLS certificates on the fly to intercept HTTPS communications (as a man-in-the-middle)
  • +
  • integrates nicely into your editor and source control: a simple hierarchy of files is generated in a clean way for inspection, edition, diffing, etc.
  • +
  • supports the HAR format to record and replay mocks, either in JSON or in YAML
  • +
  • supports HTTP/1.x and HTTP/2.0 both in client and server
  • +
+

Installation

This is a Node.js project using npm for dependency management, so ensure you have those two properly installed. Node.js LTS onwards is supported.

+

With npm, you can install it in two locations:

+
    +
  • locally inside your project and run it the usual way (using a npm script or accessing the path explicitly node_modules/.bin/kassette)
  • +
  • or install it globally and run it using the command kassette (not advised for self-contained projects)
  • +
+

Besides where it is installed, you have at least two ways to install it:

+
    +
  • from the npm registry: package's name is @amadeus-it-group/kassette
  • +
  • from a git clone (see below)
  • +
+

Installing from a git clone

Clone this repository, and run npm link to install it globally on your computer.

+

If you want to use it globally only, then there is nothing more to do.

+

If you want to install it locally though, you need to add one more step. You won't be able to use a package.json dependency, but you can install it manually using npm link @amadeus-it-group/kassette from inside your project.

+

User documentation

It is advised to start with the Getting started article which describes a few practical usage examples, then check the configuration guide and the API guide. The API reference is also available.

+

Developing / Contributing

See developer guide for details.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/index.md b/index.md deleted file mode 100644 index 22acf72c..00000000 --- a/index.md +++ /dev/null @@ -1,12 +0,0 @@ - - -[Home](./index.md) - -## API Reference - -## Packages - -| Package | Description | -| --- | --- | -| [@amadeus-it-group/kassette](./kassette.md) | kassette is a development server, used mainly for testing, which proxies requests and is able to easily manage local mocks. | - diff --git a/interfaces/APIOptions.html b/interfaces/APIOptions.html new file mode 100644 index 00000000..4992849e --- /dev/null +++ b/interfaces/APIOptions.html @@ -0,0 +1,14 @@ +APIOptions | @amadeus-it-group/kassette

Specifies the argument expected to start kassette programmatically with runFromAPI.

+
interface APIOptions {
    apiConfiguration?: ConfigurationSpec;
    configurationPath?: string;
    fileConfigurationContext?: any;
}

Properties

apiConfiguration?: ConfigurationSpec

kassette configuration passed through the API.

+

Remarks

If configurationPath is also specified, both configurations are merged, +but apiConfiguration has the least precedence. +However, this object is also forwarded to the configuration file's getConfiguration +method, as apiConfiguration, so you can apply your own logic to determine what configuration +to actually use.

+
configurationPath?: string

Path to a configuration file, if the configuration should be loaded from a configuration file.

+
fileConfigurationContext?: any

Specifies the context argument passed to the getConfiguration function defined in the +configuration file (only used if configurationPath is specified).

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/CLIConfigurationSpec.html b/interfaces/CLIConfigurationSpec.html new file mode 100644 index 00000000..2b5c1f8e --- /dev/null +++ b/interfaces/CLIConfigurationSpec.html @@ -0,0 +1,106 @@ +CLIConfigurationSpec | @amadeus-it-group/kassette

The set of possible properties defined through the CLI +(it is reduced since it can't contain runtime values)

+
interface CLIConfigurationSpec {
    delay?: Delay;
    harFileCacheTime?: number;
    hostname?: string;
    http2?: boolean;
    mocksFolder?: string;
    mocksFormat?: MocksFormat;
    mocksHarFile?: string;
    mode?: Mode;
    port?: number;
    proxyConnectMode?: ProxyConnectMode;
    remoteURL?: null | string;
    saveChecksumContent?: boolean;
    saveDetailedTimings?: boolean;
    saveForwardedRequestBody?: null | boolean;
    saveForwardedRequestData?: null | boolean;
    saveInputRequestBody?: boolean;
    saveInputRequestData?: boolean;
    skipLog?: boolean;
    tlsCAKeyPath?: null | string;
    tlsKeySize?: number;
}

Hierarchy

Properties

delay?: Delay

The default delay.

+

Remarks

It can be changed at request level in the hook method +through mock.setDelay.

+
harFileCacheTime?: number

Time in milliseconds during which a har file is kept in memory after its last usage.

+
hostname?: string

The hostname on which the proxy should listen. +Uses 127.0.0.1 by default, which only allows local connections. +To allow remote connections, use the ip address of the specific network interface that should be allowed to connect +or the unspecified IPv4 (0.0.0.0) or IPv6 (::) address.

+

Remarks

Note that kassette has not been reviewed for security issues. +It is intended to be used in a safe local/testing environment. +Binding it to an open connection can result in compromising your +computer or your network.

+
http2?: boolean

Enables http/2.0 protocol in the kassette server.

+
mocksFolder?: string

When the mocks format is 'folder', specifies +the default root folder of all mocks, from which specific mocks paths will be resolved.

+

Remarks

It can be changed at a request level in the hook method +through mock.setMocksFolder.

+
mocksFormat?: MocksFormat

The default mocks format.

+

Remarks

It can be changed at request level in the hook method +through mock.setMocksFormat.

+

The default value of the global mocksFormat setting is folder, except in the following case: +if the global mocksHarFile setting is defined +and the global mocksFolder setting is not defined, +then the default value of the global mocksFormat setting is har.

+
mocksHarFile?: string

When the mocks format is 'har', specifies +the default har file to use. If the file name has the .yml or .yaml extension, the YAML format +is used instead of the standard JSON format to read and write the file.

+

Remarks

It can be changed at a request level in the hook method +through mock.setMocksHarFile.

+
mode?: Mode

The default mode.

+

Remarks

It can be changed at request level in the hook method +through mock.setMode.

+
port?: number

The port on which the proxy should listen. Note that kassette accepts both http and https connections on this port.

+

Remarks

If the port is not available, it will fail and stop the program; try again with another, available port. +If the port is set to 0, the proxy will listen on a random port +(actually depends on the OS implementation): use the callback onListen to catch its value.

+
proxyConnectMode?: ProxyConnectMode

Default mode for CONNECT requests.

+

Remarks

It can be changed at a request level in the onProxyConnect method +through setMode.

+
remoteURL?: null | string

The URL of the remote backend, from which only the protocol, hostname and port are used. +Can be left null, in which case anything leading to sending the request to the remote backend will trigger an exception. +Can also contain the special "*" value, which means reading from the request the remote backend to target. This is useful when using kassette as a browser proxy.

+

Remarks

It can be changed at a request level in the hook method +through mock.setRemoteURL.

+
saveChecksumContent?: boolean

Whether to save the content used to create a checksum when creating a new mock with a checksum.

+

Remarks

The default value of the global saveChecksumContent setting is true.

+

It can be changed at request level in the hook method +through mock.setSaveChecksumContent.

+
saveDetailedTimings?: boolean

Whether to save detailed timings when creating a new mock.

+

Remarks

The default value of the global saveDetailedTimings setting is true.

+

It can be changed at request level in the hook method +through mock.setSaveDetailedTimings.

+
saveForwardedRequestBody?: null | boolean

Whether to save the forwarded request body when creating a new mock.

+

Remarks

The default value of the global saveForwardedRequestData setting is null, which means +true when mocksFormat is folder (for backward-compatibility), and +false when mocksFormat is har.

+

It can be changed at request level in the hook method +through mock.setSaveForwardedRequestBody.

+
saveForwardedRequestData?: null | boolean

Whether to save the forwarded request data (headers, method, URL) when creating a new mock.

+

Remarks

The default value of the global saveForwardedRequestData setting is null, which means +true when mocksFormat is folder (for backward-compatibility), and +false when mocksFormat is har.

+

It can be changed at request level in the hook method +through mock.setSaveForwardedRequestData.

+
saveInputRequestBody?: boolean

Whether to save the content of the input request body when creating a new mock.

+

Remarks

The default value of the global saveInputRequestBody setting is true.

+

It can be changed at request level in the hook method +through mock.setSaveInputRequestBody.

+
saveInputRequestData?: boolean

Whether to save the input request data (headers, method, URL) when creating a new mock.

+

Remarks

The default value of the global saveInputRequestData setting is true.

+

It can be changed at request level in the hook method +through mock.setSaveInputRequestData.

+
skipLog?: boolean

If true, will simplify the logging output, logging only one line +when the request is received but nothing else afterwards.

+
tlsCAKeyPath?: null | string

Path to a PEM-encoded CA (Certificate Authority) certificate and key file, +created if it does not exist. If not provided, the certificate and key are +generated but only kept in memory. This certificate and key are used as needed +to sign certificates generated on the fly for any HTTPS connection intercepted +by kassette.

+

Remarks

You can optionally import in the browser the TLS certificate from this +file in order to remove the warning when connecting to HTTPS websites +through kassette.

+
tlsKeySize?: number

Size in bits of generated RSA keys.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/ChecksumArgs.html b/interfaces/ChecksumArgs.html new file mode 100644 index 00000000..21487ea0 --- /dev/null +++ b/interfaces/ChecksumArgs.html @@ -0,0 +1,33 @@ +ChecksumArgs | @amadeus-it-group/kassette

Type of the argument expected by checksum. +It specifies which data from the request to include in the checksum.

+

Remarks

To include or exclude data, not every kind of data from the request has the +same complexity. For instance, the HTTP method is simple: use it or don't +use it. But for things like query parameters, headers, body: you might want to +select/filter.

+
interface ChecksumArgs {
    body?: boolean | FilterableSpec<Buffer, string | Buffer>;
    customData?: any;
    format?: BinaryToTextEncoding;
    headers?: boolean | ListOrFilter;
    hostname?: boolean | FilterableSpec<string, string>;
    method?: boolean | IncludableSpec;
    pathname?: boolean | FilterableSpec<string, string>;
    port?: boolean | IncludableSpec;
    protocol?: boolean | IncludableSpec;
    query?: boolean | ListOrFilter;
    type?: string;
}

Properties

body?: boolean | FilterableSpec<Buffer, string | Buffer>

Specifies whether and how to include the body of the request in the hash. The default value is true.

+
customData?: any

Any custom value (which can be JSON stringified) to be added in the content +to be hashed.

+
format?: BinaryToTextEncoding

Specifies the output format. Default value is hex. +Check Node.js API for more information: https://nodejs.org/api/crypto.html#crypto_hash_digest_encoding|hash.digest(format).

+
headers?: boolean | ListOrFilter

Specifies whether and how to include the headers in the hash. +The default value is false.

+
hostname?: boolean | FilterableSpec<string, string>

Specifies whether and how to include the hostname in the hash. The default value is false.

+
method?: boolean | IncludableSpec

Specifies whether to include the method in the hash. The default value is false.

+
pathname?: boolean | FilterableSpec<string, string>

Specifies whether and how to include the pathname part of the url in the hash. The default value is false.

+
port?: boolean | IncludableSpec

Specifies whether to include the port in the hash. The default value is false.

+
protocol?: boolean | IncludableSpec

Specifies whether to include the protocol in the hash. The default value is false.

+
query?: boolean | ListOrFilter

Specifies whether and how to include the query part of the url in the hash. The default value is true.

+
type?: string

Specifies the hash algorithm. Default value is sha256. +Check Node.js API for more information: https://nodejs.org/api/crypto.html#crypto_crypto_createhash_algorithm_options|crypto.createHash(type).

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/ConfigurationSpec.html b/interfaces/ConfigurationSpec.html new file mode 100644 index 00000000..f48c5aee --- /dev/null +++ b/interfaces/ConfigurationSpec.html @@ -0,0 +1,138 @@ +ConfigurationSpec | @amadeus-it-group/kassette

Augments the CLI spec to add all pure runtime properties, +that can be defined through the configuration file only

+
interface ConfigurationSpec {
    console?: ConsoleSpec;
    delay?: Delay;
    harFileCacheTime?: number;
    harMimeTypesParseJson?: string[];
    hostname?: string;
    http2?: boolean;
    mocksFolder?: string;
    mocksFormat?: MocksFormat;
    mocksHarFile?: string;
    mocksHarKeyManager?: HarKeyManager;
    mode?: Mode;
    port?: number;
    proxyConnectMode?: ProxyConnectMode;
    remoteURL?: null | string;
    saveChecksumContent?: boolean;
    saveDetailedTimings?: boolean;
    saveForwardedRequestBody?: null | boolean;
    saveForwardedRequestData?: null | boolean;
    saveInputRequestBody?: boolean;
    saveInputRequestData?: boolean;
    skipLog?: boolean;
    tlsCAKeyPath?: null | string;
    tlsKeySize?: number;
    hook?(parameters): void | Promise<void>;
    onExit?(): void;
    onListen?(parameters): void;
    onProxyConnect?(parameters): void | Promise<void>;
}

Hierarchy

Properties

console?: ConsoleSpec

Custom implementation of the ConsoleSpec interface, with methods +log and error, +each receiving one single argument of any type. +Useful to capture the logs of the application.

+
delay?: Delay

The default delay.

+

Remarks

It can be changed at request level in the hook method +through mock.setDelay.

+
harFileCacheTime?: number

Time in milliseconds during which a har file is kept in memory after its last usage.

+
harMimeTypesParseJson?: string[]

Used only when the mocks format is 'har', +specifies a list of mime types that will attempt to parse the request/response body as JSON. +If the list includes an empty string: '' and there is no mimeType set in the request, it will attempt to parse the body as JSON. +This will only be applicable to request bodies if saveInputRequestBody is set to true +Default value will be [] and will only be overridden by setHarMimeTypesParseJson

+
hostname?: string

The hostname on which the proxy should listen. +Uses 127.0.0.1 by default, which only allows local connections. +To allow remote connections, use the ip address of the specific network interface that should be allowed to connect +or the unspecified IPv4 (0.0.0.0) or IPv6 (::) address.

+

Remarks

Note that kassette has not been reviewed for security issues. +It is intended to be used in a safe local/testing environment. +Binding it to an open connection can result in compromising your +computer or your network.

+
http2?: boolean

Enables http/2.0 protocol in the kassette server.

+
mocksFolder?: string

When the mocks format is 'folder', specifies +the default root folder of all mocks, from which specific mocks paths will be resolved.

+

Remarks

It can be changed at a request level in the hook method +through mock.setMocksFolder.

+
mocksFormat?: MocksFormat

The default mocks format.

+

Remarks

It can be changed at request level in the hook method +through mock.setMocksFormat.

+

The default value of the global mocksFormat setting is folder, except in the following case: +if the global mocksHarFile setting is defined +and the global mocksFolder setting is not defined, +then the default value of the global mocksFormat setting is har.

+
mocksHarFile?: string

When the mocks format is 'har', specifies +the default har file to use. If the file name has the .yml or .yaml extension, the YAML format +is used instead of the standard JSON format to read and write the file.

+

Remarks

It can be changed at a request level in the hook method +through mock.setMocksHarFile.

+
mocksHarKeyManager?: HarKeyManager

Function called to get or set the key of a mock in a har file, as explained in HarKeyManager.

+

Remarks

It can be changed at a request level in the hook method +through mock.setMocksHarKeyManager.

+
mode?: Mode

The default mode.

+

Remarks

It can be changed at request level in the hook method +through mock.setMode.

+
port?: number

The port on which the proxy should listen. Note that kassette accepts both http and https connections on this port.

+

Remarks

If the port is not available, it will fail and stop the program; try again with another, available port. +If the port is set to 0, the proxy will listen on a random port +(actually depends on the OS implementation): use the callback onListen to catch its value.

+
proxyConnectMode?: ProxyConnectMode

Default mode for CONNECT requests.

+

Remarks

It can be changed at a request level in the onProxyConnect method +through setMode.

+
remoteURL?: null | string

The URL of the remote backend, from which only the protocol, hostname and port are used. +Can be left null, in which case anything leading to sending the request to the remote backend will trigger an exception. +Can also contain the special "*" value, which means reading from the request the remote backend to target. This is useful when using kassette as a browser proxy.

+

Remarks

It can be changed at a request level in the hook method +through mock.setRemoteURL.

+
saveChecksumContent?: boolean

Whether to save the content used to create a checksum when creating a new mock with a checksum.

+

Remarks

The default value of the global saveChecksumContent setting is true.

+

It can be changed at request level in the hook method +through mock.setSaveChecksumContent.

+
saveDetailedTimings?: boolean

Whether to save detailed timings when creating a new mock.

+

Remarks

The default value of the global saveDetailedTimings setting is true.

+

It can be changed at request level in the hook method +through mock.setSaveDetailedTimings.

+
saveForwardedRequestBody?: null | boolean

Whether to save the forwarded request body when creating a new mock.

+

Remarks

The default value of the global saveForwardedRequestData setting is null, which means +true when mocksFormat is folder (for backward-compatibility), and +false when mocksFormat is har.

+

It can be changed at request level in the hook method +through mock.setSaveForwardedRequestBody.

+
saveForwardedRequestData?: null | boolean

Whether to save the forwarded request data (headers, method, URL) when creating a new mock.

+

Remarks

The default value of the global saveForwardedRequestData setting is null, which means +true when mocksFormat is folder (for backward-compatibility), and +false when mocksFormat is har.

+

It can be changed at request level in the hook method +through mock.setSaveForwardedRequestData.

+
saveInputRequestBody?: boolean

Whether to save the content of the input request body when creating a new mock.

+

Remarks

The default value of the global saveInputRequestBody setting is true.

+

It can be changed at request level in the hook method +through mock.setSaveInputRequestBody.

+
saveInputRequestData?: boolean

Whether to save the input request data (headers, method, URL) when creating a new mock.

+

Remarks

The default value of the global saveInputRequestData setting is true.

+

It can be changed at request level in the hook method +through mock.setSaveInputRequestData.

+
skipLog?: boolean

If true, will simplify the logging output, logging only one line +when the request is received but nothing else afterwards.

+
tlsCAKeyPath?: null | string

Path to a PEM-encoded CA (Certificate Authority) certificate and key file, +created if it does not exist. If not provided, the certificate and key are +generated but only kept in memory. This certificate and key are used as needed +to sign certificates generated on the fly for any HTTPS connection intercepted +by kassette.

+

Remarks

You can optionally import in the browser the TLS certificate from this +file in order to remove the warning when connecting to HTTPS websites +through kassette.

+
tlsKeySize?: number

Size in bits of generated RSA keys.

+

Methods

  • Callback called for every HTTP request that kassette receives (with the exception of CONNECT requests, +which trigger the call of onProxyConnect instead).

    +

    Parameters

    • parameters: HookAPI

      exposes the API to control how to process the request

      +

    Returns void | Promise<void>

  • Callback called when the proxy is started and listening.

    +

    Parameters

    • parameters: {
          port: number;
      }

      the port property contains the port on which the +proxy is listening.

      +
      • port: number

    Returns void

  • Callback called when kassette receives a request with the +CONNECT method, +which usually happens when kassette is used as a browser proxy and the browser is trying to +connect to a secure web site with the https protocol.

    +

    Parameters

    • parameters: IProxyConnectAPI

      exposes the API to control how to process the request

      +

    Returns void | Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/Connection.html b/interfaces/Connection.html new file mode 100644 index 00000000..237bf7ad --- /dev/null +++ b/interfaces/Connection.html @@ -0,0 +1,8 @@ +Connection | @amadeus-it-group/kassette

A connection intercepted by kassette

+
interface Connection {
    hostname: string;
    port: number;
    protocol: string;
}

Properties

Properties

hostname: string

target hostname

+
port: number

target port

+
protocol: string

protocol such as http or https, without the trailing :

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/ConsoleSpec.html b/interfaces/ConsoleSpec.html new file mode 100644 index 00000000..66d708ef --- /dev/null +++ b/interfaces/ConsoleSpec.html @@ -0,0 +1,8 @@ +ConsoleSpec | @amadeus-it-group/kassette

Console with logging methods.

+
interface ConsoleSpec {
    error(message): void;
    log(message): void;
}

Methods

Methods

  • Logs an error message.

    +

    Parameters

    • message: any

      error message to log

      +

    Returns void

  • Logs a message.

    +

    Parameters

    • message: any

      message to log

      +

    Returns void

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/FilterableSpec.html b/interfaces/FilterableSpec.html new file mode 100644 index 00000000..a44f18eb --- /dev/null +++ b/interfaces/FilterableSpec.html @@ -0,0 +1,12 @@ +FilterableSpec | @amadeus-it-group/kassette

Interface FilterableSpec<I, O>

Interface used in ChecksumArgs for each piece of data that can be filtered (i.e. modified) before it is included +in the hash computed by the checksum method.

+
interface FilterableSpec {
    include?: boolean;
    filter?(input): O | Promise<O>;
}

Type Parameters

  • I

  • O = I

Hierarchy

Properties

Methods

Properties

include?: boolean

Whether to include this piece of data in the hash. It is true by default (if an object is passed).

+

Methods

  • A function used to filter (i.e. modify) the piece of data before it is included in the hash. +If no function is given, the unmodified piece of data is used.

    +

    Parameters

    • input: I

      piece of data to filter

      +

    Returns O | Promise<O>

    The modified piece of data. Note that the filter function can optionally be +asynchronous, in which case it is expected to return a promise of the modified piece +of data.

    +

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/GetConfigurationProps.html b/interfaces/GetConfigurationProps.html new file mode 100644 index 00000000..ea8b63a5 --- /dev/null +++ b/interfaces/GetConfigurationProps.html @@ -0,0 +1,12 @@ +GetConfigurationProps | @amadeus-it-group/kassette

Parameter of the getConfiguration function +(which a kassette configuration file is supposed to export).

+
interface GetConfigurationProps {
    apiConfiguration: ConfigurationSpec;
    cliConfiguration: CLIConfigurationSpec;
    context: any;
}

Properties

apiConfiguration: ConfigurationSpec

If run from the API, this is the configuration coming from the runFromAPI call. +Otherwise it is an empty object.

+
cliConfiguration: CLIConfigurationSpec

If run from the CLI, this is the configuration coming from the CLI. +Otherwise it is an empty object.

+
context: any

If run from the API, this is the context value provided (if any) through runFromAPI. +Otherwise it is undefined.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/HarFormatContent.html b/interfaces/HarFormatContent.html new file mode 100644 index 00000000..d70e4d3c --- /dev/null +++ b/interfaces/HarFormatContent.html @@ -0,0 +1,17 @@ +HarFormatContent | @amadeus-it-group/kassette

Information about the response body, as stored in a har file.

+
interface HarFormatContent {
    comment?: string;
    compression?: number;
    encoding?: string;
    json?: any;
    mimeType?: string;
    size?: number;
    text?: string;
}

Properties

comment?: string

Any comment as a string. This is not used by kassette.

+
compression?: number

Number of bytes saved by compression. This is not implemented by kassette.

+
encoding?: string

Encoding used for the text field, such as "base64".

+
json?: any

Response body saved as an object.

+
mimeType?: string

Value of the Content-Type response header.

+
size?: number

Size of the content in bytes.

+
text?: string

Response body.

+

Remarks

The response body can be encoded in base64 if this is specified in the encoding field.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/HarFormatEntry.html b/interfaces/HarFormatEntry.html new file mode 100644 index 00000000..6002dc7d --- /dev/null +++ b/interfaces/HarFormatEntry.html @@ -0,0 +1,35 @@ +HarFormatEntry | @amadeus-it-group/kassette

Detailed information about a request and its response, as stored in a har file.

+
interface HarFormatEntry {
    _kassetteChecksumContent?: string;
    _kassetteForwardedRequest?: HarFormatRequest;
    _kassetteMockKey?: string;
    cache?: any;
    comment?: string;
    connection?: string;
    pageref?: string;
    request?: HarFormatRequest;
    response?: HarFormatResponse;
    serverIPAddress?: string;
    startedDateTime?: string;
    time?: number;
    timings?: HarFormatTimings;
}

Properties

_kassetteChecksumContent?: string

Content used to create a checksum

+

Remarks

kassette only includes this field if saveChecksumContent is true and +if the checksum method was called.

+
_kassetteForwardedRequest?: HarFormatRequest

Detailed information about the request forwarded to the remote server.

+

Remarks

kassette only includes this field if saveInputRequestData is true.

+
_kassetteMockKey?: string

Key used by kassette to select the correct mock to replay.

+

Remarks

This field contains the value passed to IMock.setMockHarKey when used with the default +mocksHarKeyManager.

+
cache?: any

Information about the cache. This is not implemented in kassette.

+
comment?: string

Any comment as a string. This is not used by kassette.

+
connection?: string

Unique ID of the TCP/IP connection. This is not implemented in kassette.

+
pageref?: string

Reference to the parent page. This is not implemented in kassette.

+

Detailed information about the input request.

+

Remarks

kassette only includes this field if saveInputRequestData is true.

+

Detailed information about the response.

+
serverIPAddress?: string

Server IP address. This is not implemented in kassette.

+
startedDateTime?: string

Date and time of the request start, as a string in ISO format (YYYY-MM-DDThh:mm:ss.sTZD).

+
time?: number

Total time of the request, in milliseconds. This is the sum of all timings in the timings object.

+

Detailed timing information about request/response round trip.

+

Remarks

kassette only includes this field if saveDetailedTimings is true.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/HarFormatNameValuePair.html b/interfaces/HarFormatNameValuePair.html new file mode 100644 index 00000000..02858340 --- /dev/null +++ b/interfaces/HarFormatNameValuePair.html @@ -0,0 +1,8 @@ +HarFormatNameValuePair | @amadeus-it-group/kassette

Interface HarFormatNameValuePair

Information about a header or a query parameter, as stored in a har file.

+
interface HarFormatNameValuePair {
    comment?: string;
    name: string;
    value: string;
}

Properties

Properties

comment?: string

Any comment as a string. This is not used by kassette.

+
name: string

Name of the header or query parameter.

+
value: string

Value of the header or the query parameter.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/HarFormatPostData.html b/interfaces/HarFormatPostData.html new file mode 100644 index 00000000..5bbb8b42 --- /dev/null +++ b/interfaces/HarFormatPostData.html @@ -0,0 +1,13 @@ +HarFormatPostData | @amadeus-it-group/kassette

Information about a request body, as stored in a har file.

+
interface HarFormatPostData {
    comment?: string;
    json?: any;
    mimeType?: string;
    params?: any[];
    text?: string;
}

Properties

comment?: string

Any comment as a string. This is not used by kassette.

+
json?: any

Response body saved as an object.

+
mimeType?: string

Value of the Content-Type request header, if present.

+
params?: any[]

List of posted parameters. This is not implemented in kassette.

+

Remarks

kassette always fills the text field and never uses the params field.

+
text?: string

Posted data, as a (binary) string.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/HarFormatRequest.html b/interfaces/HarFormatRequest.html new file mode 100644 index 00000000..88fbc98a --- /dev/null +++ b/interfaces/HarFormatRequest.html @@ -0,0 +1,26 @@ +HarFormatRequest | @amadeus-it-group/kassette

Detailed information about a request, as stored in a har file.

+
interface HarFormatRequest {
    bodySize?: number;
    comment?: string;
    cookies?: any[];
    headers?: HarFormatNameValuePair[];
    headersSize?: number;
    httpVersion?: string;
    method?: string;
    postData?: HarFormatPostData;
    queryString?: HarFormatNameValuePair[];
    url?: string;
}

Properties

bodySize?: number

Size of the request body in bytes or -1 if it is unknown.

+
comment?: string

Any comment as a string. This is not used by kassette.

+
cookies?: any[]

Information about cookies. This is not implemented in kassette.

+

List of request headers.

+
headersSize?: number

Total number of bytes from the start of the HTTP request message until (and including) the double CRLF before the body, +or -1 if it is unknown. kassette always sets -1 for this field.

+
httpVersion?: string

Request HTTP version, such as "HTTP/1.1".

+
method?: string

Request method, such as "GET" or "POST".

+

Information about the request body.

+

Remarks

kassette only includes this field if saveInputRequestBody is true +(or, for the _kassetteForwardedRequest.postData field, +if saveForwardedRequestBody is true).

+
queryString?: HarFormatNameValuePair[]

List of query parameters.

+
url?: string

Request URL.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/HarFormatResponse.html b/interfaces/HarFormatResponse.html new file mode 100644 index 00000000..21239a15 --- /dev/null +++ b/interfaces/HarFormatResponse.html @@ -0,0 +1,23 @@ +HarFormatResponse | @amadeus-it-group/kassette

Detailed information about a response, as stored in a har file.

+
interface HarFormatResponse {
    bodySize?: number;
    comment?: string;
    content?: HarFormatContent;
    cookies?: any[];
    headers?: HarFormatNameValuePair[];
    headersSize?: number;
    httpVersion?: string;
    redirectURL?: string;
    status?: number;
    statusText?: string;
}

Properties

bodySize?: number

Size of the response body in bytes, or -1 if it is unknown.

+
comment?: string

Any comment as a string. This is not used by kassette.

+

Information about the response body.

+
cookies?: any[]

Information about cookies. This is not implemented in kassette.

+

List of response headers.

+
headersSize?: number

Total number of bytes from the start of the HTTP response message until (and including) the double CRLF before the body, +or -1 if it is unknown. kassette always sets -1 for this field.

+
httpVersion?: string

Response HTTP version, such as "HTTP/1.1".

+
redirectURL?: string

Content of the Location response header if present.

+
status?: number

Response status.

+
statusText?: string

Response status text.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/HarFormatTimings.html b/interfaces/HarFormatTimings.html new file mode 100644 index 00000000..390866bc --- /dev/null +++ b/interfaces/HarFormatTimings.html @@ -0,0 +1,23 @@ +HarFormatTimings | @amadeus-it-group/kassette

Details about the time spent for each phase of a request-response round trip, as stored in a har file.

+
interface HarFormatTimings {
    blocked?: number;
    comment?: string;
    connect?: number;
    dns?: number;
    receive?: number;
    send?: number;
    ssl?: number;
    wait?: number;
}

Hierarchy

Properties

blocked?: number

Time spent in a queue waiting for a network connection. +Can be -1 if the timing does not apply to the current request.

+
comment?: string

Any comment as a string. This is not used by kassette.

+
connect?: number

Time required to create TCP connection. +Can be -1 if the timing does not apply to the current request.

+
dns?: number

The time required to resolve a host name. +Can be -1 if the timing does not apply to the current request.

+
receive?: number

Time required to read entire response from the server.

+
send?: number

Time required to send HTTP request to the server.

+
ssl?: number

Time required for SSL/TLS negotiation. +This time is also included in the RequestTimings.connect field. +Can be -1 if the timing does not apply to the current request.

+
wait?: number

Time waiting for a response from the server.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/HookAPI.html b/interfaces/HookAPI.html new file mode 100644 index 00000000..916d78c5 --- /dev/null +++ b/interfaces/HookAPI.html @@ -0,0 +1,8 @@ +HookAPI | @amadeus-it-group/kassette

Parameter of the hook callback, that is called for every +HTTP request that kassette receives.

+
interface HookAPI {
    console: ConsoleSpec;
    mock: IMock;
}

Properties

Properties

console: ConsoleSpec

The console object as specified in the configuration, +otherwise it is the global console object (usually the one of the platform).

+
mock: IMock

Provides the API to specify how to handle the HTTP request.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/IConfigurationFile.html b/interfaces/IConfigurationFile.html new file mode 100644 index 00000000..7c0b0703 --- /dev/null +++ b/interfaces/IConfigurationFile.html @@ -0,0 +1,6 @@ +IConfigurationFile | @amadeus-it-group/kassette

Interface that a kassette configuration file should export.

+
interface IConfigurationFile {
    getConfiguration(arg): ConfigurationSpec | Promise<ConfigurationSpec>;
}

Methods

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/IConfigurationProperty.html b/interfaces/IConfigurationProperty.html new file mode 100644 index 00000000..da23cf6c --- /dev/null +++ b/interfaces/IConfigurationProperty.html @@ -0,0 +1,6 @@ +IConfigurationProperty | @amadeus-it-group/kassette

Interface IConfigurationProperty<PropertyType>

Contains the value and origin of a configuration property.

+
interface IConfigurationProperty {
    origin: ConfigurationPropertySource;
    value: PropertyType;
}

Type Parameters

  • PropertyType

Properties

Properties

The id of the source of the resolved value of the property

+
value: PropertyType

The resolved value of the property

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/IFetchedRequest.html b/interfaces/IFetchedRequest.html new file mode 100644 index 00000000..ff2fbf7a --- /dev/null +++ b/interfaces/IFetchedRequest.html @@ -0,0 +1,26 @@ +IFetchedRequest | @amadeus-it-group/kassette

A handier wrapper around a request

+
interface IFetchedRequest {
    body: Buffer;
    connection: Readonly<Connection>;
    connectionsStack: readonly Readonly<Connection>[];
    headers: IncomingHttpHeaders;
    hostname: string;
    method: string;
    original: IncomingMessage | Http2ServerRequest;
    pathname: string;
    port: string;
    protocol: string;
    queryParameters: Readonly<Record<string, string>>;
    url: URL;
}

Properties

body: Buffer

The body content

+
connection: Readonly<Connection>

The last connection in connectionsStack

+
connectionsStack: readonly Readonly<Connection>[]

The connections stack

+
headers: IncomingHttpHeaders

The headers

+
hostname: string

The hostname part of the URL

+
method: string

The HTTP method

+
original: IncomingMessage | Http2ServerRequest

The original Node.js object representing the request

+
pathname: string

The path part of the URL

+
port: string

The port part of the URL

+
protocol: string

The protocol part of the URL, without the trailing :

+
queryParameters: Readonly<Record<string, string>>

The query parameters taken from the URL, as a read-only map of strings

+
url: URL

The URL

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/IMock.html b/interfaces/IMock.html new file mode 100644 index 00000000..efdc7379 --- /dev/null +++ b/interfaces/IMock.html @@ -0,0 +1,226 @@ +IMock | @amadeus-it-group/kassette

The public interface exposed to the end user to handle a given request and the associated mock and response.

+

An object implementing this interface is passed to the hook function, under property mock of the single argument object.

+
interface IMock {
    checksumContent: null | string;
    defaultLocalPath: string;
    defaultMockHarKey?: string;
    delay: number;
    harMimeTypesParseJson: string[];
    localPath: string;
    mockFolderFullPath: string;
    mockHarKey?: string;
    mocksFolder: string;
    mocksFormat: MocksFormat;
    mocksHarFile: string;
    mocksHarKeyManager: HarKeyManager;
    mode: Mode;
    options: MockingOptions;
    remoteURL: null | string;
    request: IFetchedRequest;
    response: IResponse;
    saveChecksumContent: boolean;
    saveDetailedTimings: boolean;
    saveForwardedRequestBody: boolean;
    saveForwardedRequestData: boolean;
    saveInputRequestBody: boolean;
    saveInputRequestData: boolean;
    sourcePayload: undefined | PayloadWithOrigin<PayloadOrigin>;
    checksum(spec): Promise<string>;
    createPayload(payload): PayloadWithOrigin<"user">;
    downloadPayload(): Promise<RemotePayload>;
    fetchPayload(): Promise<RemotePayload>;
    fillResponseFromPayload(payload): void;
    getPayloadAndFillResponse(): Promise<void>;
    hasLocalFiles(): Promise<boolean>;
    hasLocalMock(): Promise<boolean>;
    hasNoLocalFiles(): Promise<boolean>;
    hasNoLocalMock(): Promise<boolean>;
    persistPayload(payload): Promise<void>;
    process(): Promise<void>;
    readLocalPayload(): Promise<undefined | PayloadWithOrigin<"user" | "local">>;
    readLocalPayloadAndFillResponse(): Promise<boolean>;
    readOrDownloadPayload(): Promise<PayloadWithOrigin<"user" | "local"> | RemotePayload>;
    readOrFetchPayload(): Promise<PayloadWithOrigin<"user" | "local"> | RemotePayload>;
    sendResponse(): Promise<void>;
    setDelay(delay): void;
    setHarMimeTypesParseJson(value): void;
    setLocalPath(pathParts): void;
    setMockHarKey(value): void;
    setMocksFolder(value): void;
    setMocksFormat(value): void;
    setMocksHarFile(value): void;
    setMocksHarKeyManager(value): void;
    setMode(mode): void;
    setPayload(payload): void;
    setRemoteURL(url): void;
    setSaveChecksumContent(value): void;
    setSaveDetailedTimings(value): void;
    setSaveForwardedRequestBody(value): void;
    setSaveForwardedRequestData(value): void;
    setSaveInputRequestBody(value): void;
    setSaveInputRequestData(value): void;
}

Properties

checksumContent: null | string

Content produced by the last call to the checksum method, +as it was passed to the hash algorithm.

+
defaultLocalPath: string

Used only when the mocks format is 'folder', specifies the default local path of the mock, relative to mocksFolder, . +It uses the URL pathname to build an equivalent folders hierarchy, +and appends the HTTP method as a leaf folder.

+
defaultMockHarKey?: string

Used only when the mocks format is 'har', specifies the default mock har key to use in case +setMockHarKey is not called with a non-null value. +It is computed by calling the mocks har key manager with the current request.

+

Remarks

Note that it is lazily computed, but once computed, it is not re-computed even if +mocksHarKeyManager changes.

+
delay: number

The currently computed delay that will be applied, configured either by a call to setDelay, +or by the global setting. Note that if the delay is set to recorded and the local mock +to use is not yet loaded, the value returned by this getter will be the default delay and not the recorded delay.

+
harMimeTypesParseJson: string[]

Used only when the mocks format is 'har', +specifies a list of mime types that will attempt to parse the request/response body as JSON. +This will only be applicable to request bodies if saveInputRequestBody is set to true +Default value will be [] and will only be overridden by setHarMimeTypesParseJson

+
localPath: string

Used only when the mocks format is 'folder', specifies the local path of the mock, relative to mocksFolder. +It is either the one set by the user through setLocalPath or defaultLocalPath.

+
mockFolderFullPath: string

Used only when the mocks format is 'folder', specifies the full, absolute path of the mock, built from localPath/defaultLocalPath, mocksFolder +and possibly options.root if mocksFolder is not absolute.

+
mockHarKey?: string

Used only when the mocks format is 'har', specifies the key to use inside the har file to either +read or write a mock.

+

Remarks

The way the key is stored inside the har file depends on the value of mocksHarKeyManager.

+
mocksFolder: string

Used only when the mocks format is 'folder', specifies the root folder of all mocks, +from which specific mocks paths will be resolved +(resolved against options.root).

+
mocksFormat: MocksFormat

The mocks format used for this request.

+
mocksHarFile: string

Used only when the mocks format is 'har', contains the full path of the the har file to use. +If the file name has the .yml or .yaml extension, the YAML format is used instead of the standard JSON format to read and write the file.

+
mocksHarKeyManager: HarKeyManager

Used only when the mocks format is 'har', specifies the har key manager to use.

+
mode: Mode

The current mode, configured either by a call to setMode, +or by the global setting.

+

Link to global configuration options

+
remoteURL: null | string

The current remote URL, configured either by a call to setRemoteURL, +or by the global setting.

+

The wrapper around the input request

+
response: IResponse

The wrapper around the output response

+
saveChecksumContent: boolean

Whether to save the content used to create a checksum when creating a new mock with a checksum for this request.

+
saveDetailedTimings: boolean

Whether to save detailed timings when creating a new mock for this request.

+
saveForwardedRequestBody: boolean

Whether to save the forwarded request body when creating a new mock for this request.

+
saveForwardedRequestData: boolean

Whether to save the forwarded request data (headers, method, URL) when creating a new mock for this request.

+
saveInputRequestBody: boolean

Whether to save the content of the input request body when creating a new mock for this request.

+
saveInputRequestData: boolean

Whether to save the input request data (headers, method, URL) when creating a new mock for this request.

+
sourcePayload: undefined | PayloadWithOrigin<PayloadOrigin>

As soon as response is filled with a payload, this property holds the reference to that +payload's wrapper. The wrapper is useful here to know where the payload comes from. +Before that, this property is undefined.

+

Methods

  • Compute a checksum using content from the request.

    +

    Parameters

    • spec: ChecksumArgs

      specifies which data from the request to include in the checksum

      +

    Returns Promise<string>

    The actual checksum value, that you can then +use for instance to add to the mock's path.

    +

    Remarks

    The computed checksum is intended to be added to the path of the mock +so that semantically different requests use different mocks.

    +

    It is difficult to predict what will actually be relevant to include in +the checksum or not for your use case, and that's why we provide many options +to include/exclude/transform data (cf ChecksumArgs).

    +

    Note that we designed the API so that it is usually not needed to +call the checksum method more than once for a given request/mock.

    +

    The method stores the computed content (which is passed to the hash +algorithm) in property checksumContent +(in the mock object), as a string. It is built according to your options +and the request's data. It is also persisted, so that you can debug more easily, +especially by committing it into your SCM to analyze changes across versions of +your code. File is along with the other files of the mock under file name checksum.

    +
  • Returns true if the mock exists locally.

    +

    Returns Promise<boolean>

    Remarks

    hasNoLocalMock returns the opposite boolean value.

    +
  • Returns true if the mock does not exist locally.

    +

    Returns Promise<boolean>

    Remarks

    hasLocalMock returns the opposite boolean value.

    +
  • Returns Promise<void>

    Remarks

    If mode is manual, this method does nothing. +It also uses a private guard to make sure it is executed only once. +Therefore, if you call it from the hook method, the automatic call made for you after the +hook execution will actually not do anything (and the same if you call it yourself multiple times).

    +
  • Returns a wrapped payload built from data persisted in local files. +If no local file is present, returns undefined.

    +

    Returns Promise<undefined | PayloadWithOrigin<"user" | "local">>

  • Sends the response back to the client, with the previously specified delay +if the payload origin is not remote.

    +

    Returns Promise<void>

  • Sets the delay that will be used to send the response to the client +when the data is taken from the local mock.

    +

    Parameters

    • delay: null | Delay

      can be either a number (to directly specify the delay in milliseconds), +'recorded' (to read the delay from the time property of an already recorded mock if any) +or null (to remove the effect of any previous call of setDelay and use the default value from the global setting instead).

      +

    Returns void

  • Sets the localPath value.

    +

    Parameters

    • pathParts: RecursiveArray<undefined | null | string>

      Any combination of values and array of values, +which will eventually all be flattened, converted to strings and +joined to build a path.

      +

    Returns void

    Example

    The following example will use the HTTP method followed by the URL pathname:

    +
    mock.setLocalPath([mock.request.method, mock.request.pathname])
    +
    +

    Example

    The following example will concatenate prefix, all portions of the +URL pathname except the first one (also excluding the very first one which is empty since IFetchedRequest.pathname has a leading slash) +and optionally a suffix sequence depending on a boolean.

    +
    mock.setLocalPath([prefix, mock.request.pathname.split('/').slice(2), addSuffix ? [suffix, '-static-suffix'] : null])
    +
    +
  • Sets the mockHarKey value.

    +

    Parameters

    • value: RecursiveArray<undefined | null | string>

      specifies the key to use inside the har file to either read or write a mock. If an array is set (which can be nested), +it is flattened with null items removed, and joined with forward slashes to produce a string. +Passing null resets the value to the default value.

      +

    Returns void

  • Sets the current local payload, with a custom one you would have created.

    +

    Parameters

    Returns void

  • Sets the saveChecksumContent value.

    +

    Parameters

    • value: null | boolean

      whether to save the content used to create a checksum when creating a new mock with a checksum for this request. +Passing null resets the value to the default coming from the global setting.

      +

    Returns void

  • Sets the saveForwardedRequestData value.

    +

    Parameters

    • value: null | boolean

      whether to save the forwarded request data (headers, method, URL) when creating a new mock for this request. +Passing null resets the value to the default coming from the global setting.

      +

    Returns void

  • Sets the saveInputRequestBody value.

    +

    Parameters

    • value: null | boolean

      whether to save the content of the input request body when creating a new mock for this request. +Passing null resets the value to the default coming from the global setting.

      +

    Returns void

  • Sets the saveInputRequestData value.

    +

    Parameters

    • value: null | boolean

      whether to save the input request data (headers, method, URL) when creating a new mock for this request. +Passing null resets the value to the default coming from the global setting.

      +

    Returns void

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/IProxyConnectAPI.html b/interfaces/IProxyConnectAPI.html new file mode 100644 index 00000000..f7737212 --- /dev/null +++ b/interfaces/IProxyConnectAPI.html @@ -0,0 +1,37 @@ +IProxyConnectAPI | @amadeus-it-group/kassette

A handier wrapper around a CONNECT request

+
interface IProxyConnectAPI {
    connection: Readonly<Connection>;
    connectionsStack: readonly Readonly<Connection>[];
    destinationHostname: string;
    destinationPort: number;
    hostname: string;
    mode: ProxyConnectMode;
    port: number;
    request: IncomingMessage | Http2ServerRequest;
    socket: Socket | ServerHttp2Stream;
    process(): void;
    setDestination(hostname, port): void;
    setMode(mode): void;
}

Properties

connection: Readonly<Connection>

The last connection in connectionsStack

+
connectionsStack: readonly Readonly<Connection>[]

The connections stack

+
destinationHostname: string

The destination hostname that will be used in forward mode. +By default, it is equal to hostname. +Can be changed with setDestination.

+
destinationPort: number

The destination port that will be used in forward mode. +By default, it is equal to port. +Can be changed with setDestination.

+
hostname: string

The target hostname in the CONNECT request

+

The currently selected mode, configured either by a call to setMode +or by the global setting

+
port: number

The target port in the CONNECT request

+
request: IncomingMessage | Http2ServerRequest

The original Node.js object representing the request

+
socket: Socket | ServerHttp2Stream

The underlying socket

+

Methods

  • Processes the socket according to the mode stored in mode. This method is called automatically when the +onProxyConnect function finishes, but it can also be called manually before.

    +

    Returns void

  • Sets the destination hostname and port +that will be used when the process method is called. +Also changes the mode to forward.

    +

    Parameters

    • hostname: string

      Destination hostname

      +
    • port: number

      Destination port

      +

    Returns void

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/IResponse.html b/interfaces/IResponse.html new file mode 100644 index 00000000..6a4e4b13 --- /dev/null +++ b/interfaces/IResponse.html @@ -0,0 +1,28 @@ +IResponse | @amadeus-it-group/kassette

A handier wrapper around a server response

+
interface IResponse {
    body: any;
    headers: Readonly<IncomingHttpHeaders>;
    json: boolean;
    original: ServerResponse<IncomingMessage> | Http2ServerResponse;
    status: null | Partial<Readonly<Status>>;
    send(): Promise<void>;
    setData(data): void;
    setHeaders(headers?): Readonly<IncomingHttpHeaders>;
}

Properties

body: any

The body of the response.

+

Remarks

If json is explicitly set to true, it will be serialized into JSON (and content-type header will be set to application/json). +It will also be if json is not explicitly set but the body value is not a string, not a Buffer, and not null either. +After that, the result will eventually be converted to a Buffer to be sent.

+
headers: Readonly<IncomingHttpHeaders>

The currently set headers. +Use setHeaders to change them.

+
json: boolean

Whether the body field should be serialized into JSON (and content-type header should be set to application/json).

+

Remarks

When not explicitly set, the returned value will still be true +if the body value is not a string, not a Buffer, and not null either.

+
original: ServerResponse<IncomingMessage> | Http2ServerResponse

The original Node.js object representing the response

+
status: null | Partial<Readonly<Status>>

An object {code, message}, where each property is optional. +If code is never given, a default value of 200 is applied.

+

Methods

  • Sends the response, applying some data previously specified but not set yet

    +

    Returns Promise<void>

  • A convenient method to set the body value and +set json to true.

    +

    Parameters

    • data: any

      json object to use as the response body

      +

    Returns void

  • Merge given headers map with the previously set headers (initial set is an empty map).

    +

    Parameters

    • Optional headers: Readonly<IncomingHttpHeaders>

      Headers to set. Each header value can be a number, a string, or an array of strings. Put a null value to suppress a header

      +

    Returns Readonly<IncomingHttpHeaders>

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/IncludableSpec.html b/interfaces/IncludableSpec.html new file mode 100644 index 00000000..2ba1fe2f --- /dev/null +++ b/interfaces/IncludableSpec.html @@ -0,0 +1,5 @@ +IncludableSpec | @amadeus-it-group/kassette

Base interface used in ChecksumArgs for each piece of data that can be included or not in the hash computed +by the checksum method.

+
interface IncludableSpec {
    include?: boolean;
}

Hierarchy

Properties

Properties

include?: boolean

Whether to include this piece of data in the hash. It is true by default (if an object is passed).

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/MockData.html b/interfaces/MockData.html new file mode 100644 index 00000000..9ee66e10 --- /dev/null +++ b/interfaces/MockData.html @@ -0,0 +1,22 @@ +MockData | @amadeus-it-group/kassette

The data representing the mock, which is persisted and used for serving the mock

+
interface MockData {
    bodyFileName: string;
    creationDateTime?: Date;
    headers?: Readonly<IncomingHttpHeaders>;
    httpVersion?: string;
    ignoredHeaders?: Readonly<IncomingHttpHeaders>;
    status: Readonly<Status>;
    time: number;
    timings?: RequestTimings;
}

Properties

bodyFileName: string

The name of the local file containing the body content (needed since the name is dynamic)

+
creationDateTime?: Date

Timestamp when the payload was created.

+
headers?: Readonly<IncomingHttpHeaders>

Recorded headers to be served back, without the ignored ones.

+
httpVersion?: string

Http version of the server when the mock was recorded. Will most likely be '1.1' or perhaps '1.0'. +It is not used when replaying responses.

+
ignoredHeaders?: Readonly<IncomingHttpHeaders>

Ignored headers, which are recorded headers that should not be served back. +In practice, this is mainly the content-length header (because the content-length header that is +actually served back is computed based on the actual data to send).

+
status: Readonly<Status>

HTTP status.

+
time: number

Time used by the server to process the request. +It is used to simulate the real processing time when mocking the server if the delay is set to recorded.

+
timings?: RequestTimings

Detailed timings recorded during the request.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/MockingOptions.html b/interfaces/MockingOptions.html new file mode 100644 index 00000000..e8b3f6a3 --- /dev/null +++ b/interfaces/MockingOptions.html @@ -0,0 +1,7 @@ +MockingOptions | @amadeus-it-group/kassette

Configuration options, including the root folder used to resolve +relative paths and the current global configuration.

+
interface MockingOptions {
    root: string;
    userConfiguration: IMergedConfiguration;
}

Properties

Properties

root: string

The root folder from which to resolve given relative paths

+
userConfiguration: IMergedConfiguration

The current global user configuration

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/Payload.html b/interfaces/Payload.html new file mode 100644 index 00000000..d784d7a1 --- /dev/null +++ b/interfaces/Payload.html @@ -0,0 +1,9 @@ +Payload | @amadeus-it-group/kassette

The payload represents the content of an HTTP response from the backend, no matter if it actually comes from it or if it was created manually.

+

Remarks

A payload is often wrapped in PayloadWithOrigin. To create the wrapped payload, you can use createPayload.

+

From the wrapped payload, response to the client can be filled with fillResponseFromPayload.

+

The payload can also be persisted and read, to avoid contacting the backend later on.

+
interface Payload {
    body: null | string | Buffer;
    data: MockData;
}

Properties

Properties

body: null | string | Buffer

Body of the HTTP response.

+
data: MockData

Data such as http status and headers, response delay.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/PayloadWithOrigin.html b/interfaces/PayloadWithOrigin.html new file mode 100644 index 00000000..c9dc7a9d --- /dev/null +++ b/interfaces/PayloadWithOrigin.html @@ -0,0 +1,6 @@ +PayloadWithOrigin | @amadeus-it-group/kassette

Interface PayloadWithOrigin<Origin>

Contains the payload along with its origin.

+
interface PayloadWithOrigin {
    origin: Origin;
    payload: Payload;
}

Type Parameters

Hierarchy

Properties

Properties

origin: Origin

Origin of the payload.

+
payload: Payload

Content of the payload.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/RemotePayload.html b/interfaces/RemotePayload.html new file mode 100644 index 00000000..13af42de --- /dev/null +++ b/interfaces/RemotePayload.html @@ -0,0 +1,8 @@ +RemotePayload | @amadeus-it-group/kassette

Remote payload and the request that was made to get it.

+
interface RemotePayload {
    origin: "remote";
    payload: Payload;
    requestOptions: RequestPayload;
}

Hierarchy

Properties

origin: "remote"

Origin of the payload.

+
payload: Payload

Content of the payload.

+
requestOptions: RequestPayload

Request used to get this remote payload.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/RequestPayload.html b/interfaces/RequestPayload.html new file mode 100644 index 00000000..b8687b67 --- /dev/null +++ b/interfaces/RequestPayload.html @@ -0,0 +1,10 @@ +RequestPayload | @amadeus-it-group/kassette

Content of an HTTP request.

+
interface RequestPayload {
    body?: string | Buffer;
    headers: IncomingHttpHeaders;
    method: string;
    url: string;
}

Properties

Properties

body?: string | Buffer

HTTP request body

+
headers: IncomingHttpHeaders

HTTP headers

+
method: string

HTTP method

+
url: string

HTTP url

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/RequestTimings.html b/interfaces/RequestTimings.html new file mode 100644 index 00000000..e18c1a4e --- /dev/null +++ b/interfaces/RequestTimings.html @@ -0,0 +1,21 @@ +RequestTimings | @amadeus-it-group/kassette

Details about the time spent for each phase of a request-response round trip. All times are specified in milliseconds.

+
interface RequestTimings {
    blocked?: number;
    connect?: number;
    dns?: number;
    receive?: number;
    send?: number;
    ssl?: number;
    wait?: number;
}

Hierarchy

Properties

blocked?: number

Time spent in a queue waiting for a network connection. +Can be -1 if the timing does not apply to the current request.

+
connect?: number

Time required to create TCP connection. +Can be -1 if the timing does not apply to the current request.

+
dns?: number

The time required to resolve a host name. +Can be -1 if the timing does not apply to the current request.

+
receive?: number

Time required to read entire response from the server.

+
send?: number

Time required to send HTTP request to the server.

+
ssl?: number

Time required for SSL/TLS negotiation. +This time is also included in the RequestTimings.connect field. +Can be -1 if the timing does not apply to the current request.

+
wait?: number

Time waiting for a response from the server.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/Status.html b/interfaces/Status.html new file mode 100644 index 00000000..86e0e45e --- /dev/null +++ b/interfaces/Status.html @@ -0,0 +1,6 @@ +Status | @amadeus-it-group/kassette

Generated using TypeDoc

\ No newline at end of file diff --git a/kassette.apioptions.apiconfiguration.md b/kassette.apioptions.apiconfiguration.md deleted file mode 100644 index e1f396c5..00000000 --- a/kassette.apioptions.apiconfiguration.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [APIOptions](./kassette.apioptions.md) > [apiConfiguration](./kassette.apioptions.apiconfiguration.md) - -## APIOptions.apiConfiguration property - -kassette configuration passed through the API. - -**Signature:** - -```typescript -readonly apiConfiguration?: ConfigurationSpec; -``` - -## Remarks - -If [configurationPath](./kassette.apioptions.configurationpath.md) is also specified, both configurations are merged, but `apiConfiguration` has the least precedence. However, this object is also forwarded to the configuration file's [getConfiguration](./kassette.iconfigurationfile.getconfiguration.md) method, as [apiConfiguration](./kassette.getconfigurationprops.apiconfiguration.md), so you can apply your own logic to determine what configuration to actually use. - diff --git a/kassette.apioptions.configurationpath.md b/kassette.apioptions.configurationpath.md deleted file mode 100644 index 9c2b7a6f..00000000 --- a/kassette.apioptions.configurationpath.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [APIOptions](./kassette.apioptions.md) > [configurationPath](./kassette.apioptions.configurationpath.md) - -## APIOptions.configurationPath property - -Path to a configuration file, if the configuration should be loaded from a configuration file. - -**Signature:** - -```typescript -readonly configurationPath?: string; -``` diff --git a/kassette.apioptions.fileconfigurationcontext.md b/kassette.apioptions.fileconfigurationcontext.md deleted file mode 100644 index 6b43cf11..00000000 --- a/kassette.apioptions.fileconfigurationcontext.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [APIOptions](./kassette.apioptions.md) > [fileConfigurationContext](./kassette.apioptions.fileconfigurationcontext.md) - -## APIOptions.fileConfigurationContext property - -Specifies the context argument passed to the [getConfiguration](./kassette.iconfigurationfile.getconfiguration.md) function defined in the configuration file (only used if [configurationPath](./kassette.apioptions.configurationpath.md) is specified). - -**Signature:** - -```typescript -readonly fileConfigurationContext?: any; -``` diff --git a/kassette.apioptions.md b/kassette.apioptions.md deleted file mode 100644 index a0a1c465..00000000 --- a/kassette.apioptions.md +++ /dev/null @@ -1,22 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [APIOptions](./kassette.apioptions.md) - -## APIOptions interface - -Specifies the argument expected to start kassette programmatically with [runFromAPI()](./kassette.runfromapi.md). - -**Signature:** - -```typescript -export interface APIOptions -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [apiConfiguration?](./kassette.apioptions.apiconfiguration.md) | readonly | [ConfigurationSpec](./kassette.configurationspec.md) | _(Optional)_ kassette configuration passed through the API. | -| [configurationPath?](./kassette.apioptions.configurationpath.md) | readonly | string | _(Optional)_ Path to a configuration file, if the configuration should be loaded from a configuration file. | -| [fileConfigurationContext?](./kassette.apioptions.fileconfigurationcontext.md) | readonly | any | _(Optional)_ Specifies the context argument passed to the [getConfiguration](./kassette.iconfigurationfile.getconfiguration.md) function defined in the configuration file (only used if [configurationPath](./kassette.apioptions.configurationpath.md) is specified). | - diff --git a/kassette.checksumargs.body.md b/kassette.checksumargs.body.md deleted file mode 100644 index 3af6e61d..00000000 --- a/kassette.checksumargs.body.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [body](./kassette.checksumargs.body.md) - -## ChecksumArgs.body property - -Specifies whether and how to include the body of the request in the hash. The default value is `true`. - -**Signature:** - -```typescript -body?: FilterableSpec | boolean; -``` diff --git a/kassette.checksumargs.customdata.md b/kassette.checksumargs.customdata.md deleted file mode 100644 index b1e0f618..00000000 --- a/kassette.checksumargs.customdata.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [customData](./kassette.checksumargs.customdata.md) - -## ChecksumArgs.customData property - -Any custom value (which can be JSON stringified) to be added in the content to be hashed. - -**Signature:** - -```typescript -customData?: any | null; -``` diff --git a/kassette.checksumargs.format.md b/kassette.checksumargs.format.md deleted file mode 100644 index 6384cfaa..00000000 --- a/kassette.checksumargs.format.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [format](./kassette.checksumargs.format.md) - -## ChecksumArgs.format property - -Specifies the output format. Default value is `hex`. Check Node.js API for more information: [hash.digest(format)](https://nodejs.org/api/crypto.html#crypto_hash_digest_encoding). - -**Signature:** - -```typescript -format?: crypto.BinaryToTextEncoding; -``` diff --git a/kassette.checksumargs.headers.md b/kassette.checksumargs.headers.md deleted file mode 100644 index 12927ec7..00000000 --- a/kassette.checksumargs.headers.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [headers](./kassette.checksumargs.headers.md) - -## ChecksumArgs.headers property - -Specifies whether and how to include the headers in the hash. The default value is `false`. - -**Signature:** - -```typescript -headers?: ListOrFilter | boolean; -``` diff --git a/kassette.checksumargs.hostname.md b/kassette.checksumargs.hostname.md deleted file mode 100644 index 3e89ae99..00000000 --- a/kassette.checksumargs.hostname.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [hostname](./kassette.checksumargs.hostname.md) - -## ChecksumArgs.hostname property - -Specifies whether and how to include the hostname in the hash. The default value is `false`. - -**Signature:** - -```typescript -hostname?: FilterableSpec | boolean; -``` diff --git a/kassette.checksumargs.md b/kassette.checksumargs.md deleted file mode 100644 index e28d5d82..00000000 --- a/kassette.checksumargs.md +++ /dev/null @@ -1,34 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) - -## ChecksumArgs interface - -Type of the argument expected by [checksum](./kassette.imock.checksum.md). It specifies which data from the request to include in the checksum. - -**Signature:** - -```typescript -export interface ChecksumArgs -``` - -## Remarks - -To include or exclude data, not every kind of data from the request has the same complexity. For instance, the HTTP method is simple: use it or don't use it. But for things like query parameters, headers, body: you might want to select/filter. - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [body?](./kassette.checksumargs.body.md) | | [FilterableSpec](./kassette.filterablespec.md)<Buffer, Buffer \| string> \| boolean | _(Optional)_ Specifies whether and how to include the body of the request in the hash. The default value is true. | -| [customData?](./kassette.checksumargs.customdata.md) | | any \| null | _(Optional)_ Any custom value (which can be JSON stringified) to be added in the content to be hashed. | -| [format?](./kassette.checksumargs.format.md) | | crypto.BinaryToTextEncoding | _(Optional)_ Specifies the output format. Default value is hex. Check Node.js API for more information: [hash.digest(format)](https://nodejs.org/api/crypto.html#crypto_hash_digest_encoding). | -| [headers?](./kassette.checksumargs.headers.md) | | [ListOrFilter](./kassette.listorfilter.md) \| boolean | _(Optional)_ Specifies whether and how to include the headers in the hash. The default value is false. | -| [hostname?](./kassette.checksumargs.hostname.md) | | [FilterableSpec](./kassette.filterablespec.md)<string> \| boolean | _(Optional)_ Specifies whether and how to include the hostname in the hash. The default value is false. | -| [method?](./kassette.checksumargs.method.md) | | [IncludableSpec](./kassette.includablespec.md) \| boolean | _(Optional)_ Specifies whether to include the method in the hash. The default value is false. | -| [pathname?](./kassette.checksumargs.pathname.md) | | [FilterableSpec](./kassette.filterablespec.md)<string> \| boolean | _(Optional)_ Specifies whether and how to include the pathname part of the url in the hash. The default value is false. | -| [port?](./kassette.checksumargs.port.md) | | [IncludableSpec](./kassette.includablespec.md) \| boolean | _(Optional)_ Specifies whether to include the port in the hash. The default value is false. | -| [protocol?](./kassette.checksumargs.protocol.md) | | [IncludableSpec](./kassette.includablespec.md) \| boolean | _(Optional)_ Specifies whether to include the protocol in the hash. The default value is false. | -| [query?](./kassette.checksumargs.query.md) | | [ListOrFilter](./kassette.listorfilter.md) \| boolean | _(Optional)_ Specifies whether and how to include the query part of the url in the hash. The default value is true. | -| [type?](./kassette.checksumargs.type.md) | | string | _(Optional)_ Specifies the hash algorithm. Default value is sha256. Check Node.js API for more information: [crypto.createHash(type)](https://nodejs.org/api/crypto.html#crypto_crypto_createhash_algorithm_options). | - diff --git a/kassette.checksumargs.method.md b/kassette.checksumargs.method.md deleted file mode 100644 index dd5d67e1..00000000 --- a/kassette.checksumargs.method.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [method](./kassette.checksumargs.method.md) - -## ChecksumArgs.method property - -Specifies whether to include the method in the hash. The default value is `false`. - -**Signature:** - -```typescript -method?: IncludableSpec | boolean; -``` diff --git a/kassette.checksumargs.pathname.md b/kassette.checksumargs.pathname.md deleted file mode 100644 index 0a669db8..00000000 --- a/kassette.checksumargs.pathname.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [pathname](./kassette.checksumargs.pathname.md) - -## ChecksumArgs.pathname property - -Specifies whether and how to include the pathname part of the url in the hash. The default value is `false`. - -**Signature:** - -```typescript -pathname?: FilterableSpec | boolean; -``` diff --git a/kassette.checksumargs.port.md b/kassette.checksumargs.port.md deleted file mode 100644 index 4851df94..00000000 --- a/kassette.checksumargs.port.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [port](./kassette.checksumargs.port.md) - -## ChecksumArgs.port property - -Specifies whether to include the port in the hash. The default value is `false`. - -**Signature:** - -```typescript -port?: IncludableSpec | boolean; -``` diff --git a/kassette.checksumargs.protocol.md b/kassette.checksumargs.protocol.md deleted file mode 100644 index 8fc604bf..00000000 --- a/kassette.checksumargs.protocol.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [protocol](./kassette.checksumargs.protocol.md) - -## ChecksumArgs.protocol property - -Specifies whether to include the protocol in the hash. The default value is `false`. - -**Signature:** - -```typescript -protocol?: IncludableSpec | boolean; -``` diff --git a/kassette.checksumargs.query.md b/kassette.checksumargs.query.md deleted file mode 100644 index dd2b1097..00000000 --- a/kassette.checksumargs.query.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [query](./kassette.checksumargs.query.md) - -## ChecksumArgs.query property - -Specifies whether and how to include the query part of the url in the hash. The default value is `true`. - -**Signature:** - -```typescript -query?: ListOrFilter | boolean; -``` diff --git a/kassette.checksumargs.type.md b/kassette.checksumargs.type.md deleted file mode 100644 index 84434d93..00000000 --- a/kassette.checksumargs.type.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ChecksumArgs](./kassette.checksumargs.md) > [type](./kassette.checksumargs.type.md) - -## ChecksumArgs.type property - -Specifies the hash algorithm. Default value is `sha256`. Check Node.js API for more information: [crypto.createHash(type)](https://nodejs.org/api/crypto.html#crypto_crypto_createhash_algorithm_options). - -**Signature:** - -```typescript -type?: string; -``` diff --git a/kassette.cliconfigurationspec.delay.md b/kassette.cliconfigurationspec.delay.md deleted file mode 100644 index f8c78307..00000000 --- a/kassette.cliconfigurationspec.delay.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [delay](./kassette.cliconfigurationspec.delay.md) - -## CLIConfigurationSpec.delay property - -The default delay. - -**Signature:** - -```typescript -readonly delay?: Delay; -``` - -## Remarks - -It can be changed at request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setDelay](./kassette.imock.setdelay.md). - diff --git a/kassette.cliconfigurationspec.harfilecachetime.md b/kassette.cliconfigurationspec.harfilecachetime.md deleted file mode 100644 index 39367e70..00000000 --- a/kassette.cliconfigurationspec.harfilecachetime.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [harFileCacheTime](./kassette.cliconfigurationspec.harfilecachetime.md) - -## CLIConfigurationSpec.harFileCacheTime property - -Time in milliseconds during which a har file is kept in memory after its last usage. - -**Signature:** - -```typescript -readonly harFileCacheTime?: number; -``` diff --git a/kassette.cliconfigurationspec.hostname.md b/kassette.cliconfigurationspec.hostname.md deleted file mode 100644 index 9502fa46..00000000 --- a/kassette.cliconfigurationspec.hostname.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [hostname](./kassette.cliconfigurationspec.hostname.md) - -## CLIConfigurationSpec.hostname property - -The hostname on which the proxy should listen. Uses `127.0.0.1` by default, which only allows local connections. To allow remote connections, use the ip address of the specific network interface that should be allowed to connect or the unspecified IPv4 (`0.0.0.0`) or IPv6 (`::`) address. - -**Signature:** - -```typescript -readonly hostname?: string; -``` - -## Remarks - -Note that kassette has not been reviewed for security issues. It is intended to be used in a safe local/testing environment. Binding it to an open connection can result in compromising your computer or your network. - diff --git a/kassette.cliconfigurationspec.http2.md b/kassette.cliconfigurationspec.http2.md deleted file mode 100644 index 35b0cf2d..00000000 --- a/kassette.cliconfigurationspec.http2.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [http2](./kassette.cliconfigurationspec.http2.md) - -## CLIConfigurationSpec.http2 property - -Enables http/2.0 protocol in the kassette server. - -**Signature:** - -```typescript -readonly http2?: boolean; -``` diff --git a/kassette.cliconfigurationspec.md b/kassette.cliconfigurationspec.md deleted file mode 100644 index 9c5db477..00000000 --- a/kassette.cliconfigurationspec.md +++ /dev/null @@ -1,39 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) - -## CLIConfigurationSpec interface - -The set of possible properties defined through the CLI (it is reduced since it can't contain runtime values) - -**Signature:** - -```typescript -export interface CLIConfigurationSpec -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [delay?](./kassette.cliconfigurationspec.delay.md) | readonly | [Delay](./kassette.delay.md) | _(Optional)_ The default delay. | -| [harFileCacheTime?](./kassette.cliconfigurationspec.harfilecachetime.md) | readonly | number | _(Optional)_ Time in milliseconds during which a har file is kept in memory after its last usage. | -| [hostname?](./kassette.cliconfigurationspec.hostname.md) | readonly | string | _(Optional)_ The hostname on which the proxy should listen. Uses 127.0.0.1 by default, which only allows local connections. To allow remote connections, use the ip address of the specific network interface that should be allowed to connect or the unspecified IPv4 (0.0.0.0) or IPv6 (::) address. | -| [http2?](./kassette.cliconfigurationspec.http2.md) | readonly | boolean | _(Optional)_ Enables http/2.0 protocol in the kassette server. | -| [mocksFolder?](./kassette.cliconfigurationspec.mocksfolder.md) | readonly | string | _(Optional)_ When the [mocks format](./kassette.cliconfigurationspec.mocksformat.md) is 'folder', specifies the default root folder of all mocks, from which specific mocks paths will be resolved. | -| [mocksFormat?](./kassette.cliconfigurationspec.mocksformat.md) | readonly | [MocksFormat](./kassette.mocksformat.md) | _(Optional)_ The default mocks format. | -| [mocksHarFile?](./kassette.cliconfigurationspec.mocksharfile.md) | readonly | string | _(Optional)_ When the [mocks format](./kassette.cliconfigurationspec.mocksformat.md) is 'har', specifies the default har file to use. If the file name has the .yml or .yaml extension, the YAML format is used instead of the standard JSON format to read and write the file. | -| [mode?](./kassette.cliconfigurationspec.mode.md) | readonly | [Mode](./kassette.mode.md) | _(Optional)_ The default mode. | -| [port?](./kassette.cliconfigurationspec.port.md) | readonly | number | _(Optional)_ The port on which the proxy should listen. Note that kassette accepts both http and https connections on this port. | -| [proxyConnectMode?](./kassette.cliconfigurationspec.proxyconnectmode.md) | readonly | [ProxyConnectMode](./kassette.proxyconnectmode.md) | _(Optional)_ Default mode for CONNECT requests. | -| [remoteURL?](./kassette.cliconfigurationspec.remoteurl.md) | readonly | string \| null | _(Optional)_ The URL of the remote backend, from which only the protocol, hostname and port are used. Can be left null, in which case anything leading to sending the request to the remote backend will trigger an exception. Can also contain the special "*" value, which means reading from the request the remote backend to target. This is useful when using kassette as a browser proxy. | -| [saveChecksumContent?](./kassette.cliconfigurationspec.savechecksumcontent.md) | readonly | boolean | _(Optional)_ Whether to save the content used to create a checksum when creating a new mock with a checksum. | -| [saveDetailedTimings?](./kassette.cliconfigurationspec.savedetailedtimings.md) | readonly | boolean | _(Optional)_ Whether to save [detailed timings](./kassette.requesttimings.md) when creating a new mock. | -| [saveForwardedRequestBody?](./kassette.cliconfigurationspec.saveforwardedrequestbody.md) | readonly | boolean \| null | _(Optional)_ Whether to save the forwarded request body when creating a new mock. | -| [saveForwardedRequestData?](./kassette.cliconfigurationspec.saveforwardedrequestdata.md) | readonly | boolean \| null | _(Optional)_ Whether to save the forwarded request data (headers, method, URL) when creating a new mock. | -| [saveInputRequestBody?](./kassette.cliconfigurationspec.saveinputrequestbody.md) | readonly | boolean | _(Optional)_ Whether to save the content of the input request body when creating a new mock. | -| [saveInputRequestData?](./kassette.cliconfigurationspec.saveinputrequestdata.md) | readonly | boolean | _(Optional)_ Whether to save the input request data (headers, method, URL) when creating a new mock. | -| [skipLog?](./kassette.cliconfigurationspec.skiplog.md) | readonly | boolean | _(Optional)_ If true, will simplify the logging output, logging only one line when the request is received but nothing else afterwards. | -| [tlsCAKeyPath?](./kassette.cliconfigurationspec.tlscakeypath.md) | readonly | string \| null | _(Optional)_ Path to a PEM-encoded CA (Certificate Authority) certificate and key file, created if it does not exist. If not provided, the certificate and key are generated but only kept in memory. This certificate and key are used as needed to sign certificates generated on the fly for any HTTPS connection intercepted by kassette. | -| [tlsKeySize?](./kassette.cliconfigurationspec.tlskeysize.md) | readonly | number | _(Optional)_ Size in bits of generated RSA keys. | - diff --git a/kassette.cliconfigurationspec.mocksfolder.md b/kassette.cliconfigurationspec.mocksfolder.md deleted file mode 100644 index 13c5ca57..00000000 --- a/kassette.cliconfigurationspec.mocksfolder.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [mocksFolder](./kassette.cliconfigurationspec.mocksfolder.md) - -## CLIConfigurationSpec.mocksFolder property - -When the [mocks format](./kassette.cliconfigurationspec.mocksformat.md) is 'folder', specifies the default root folder of all mocks, from which specific mocks paths will be resolved. - -**Signature:** - -```typescript -readonly mocksFolder?: string; -``` - -## Remarks - -It can be changed at a request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setMocksFolder](./kassette.imock.setmocksfolder.md). - diff --git a/kassette.cliconfigurationspec.mocksformat.md b/kassette.cliconfigurationspec.mocksformat.md deleted file mode 100644 index 3de74248..00000000 --- a/kassette.cliconfigurationspec.mocksformat.md +++ /dev/null @@ -1,20 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [mocksFormat](./kassette.cliconfigurationspec.mocksformat.md) - -## CLIConfigurationSpec.mocksFormat property - -The default mocks format. - -**Signature:** - -```typescript -readonly mocksFormat?: MocksFormat; -``` - -## Remarks - -It can be changed at request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setMocksFormat](./kassette.imock.setmocksformat.md). - -The default value of the global `mocksFormat` setting is `folder`, except in the following case: if the global [mocksHarFile](./kassette.cliconfigurationspec.mocksharfile.md) setting is defined and the global [mocksFolder](./kassette.cliconfigurationspec.mocksfolder.md) setting is not defined, then the default value of the global `mocksFormat` setting is `har`. - diff --git a/kassette.cliconfigurationspec.mocksharfile.md b/kassette.cliconfigurationspec.mocksharfile.md deleted file mode 100644 index 8e9aeca5..00000000 --- a/kassette.cliconfigurationspec.mocksharfile.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [mocksHarFile](./kassette.cliconfigurationspec.mocksharfile.md) - -## CLIConfigurationSpec.mocksHarFile property - -When the [mocks format](./kassette.cliconfigurationspec.mocksformat.md) is 'har', specifies the default har file to use. If the file name has the `.yml` or `.yaml` extension, the YAML format is used instead of the standard JSON format to read and write the file. - -**Signature:** - -```typescript -readonly mocksHarFile?: string; -``` - -## Remarks - -It can be changed at a request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setMocksHarFile](./kassette.imock.setmocksharfile.md). - diff --git a/kassette.cliconfigurationspec.mode.md b/kassette.cliconfigurationspec.mode.md deleted file mode 100644 index 3aa639b0..00000000 --- a/kassette.cliconfigurationspec.mode.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [mode](./kassette.cliconfigurationspec.mode.md) - -## CLIConfigurationSpec.mode property - -The default mode. - -**Signature:** - -```typescript -readonly mode?: Mode; -``` - -## Remarks - -It can be changed at request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setMode](./kassette.imock.setmode.md). - diff --git a/kassette.cliconfigurationspec.port.md b/kassette.cliconfigurationspec.port.md deleted file mode 100644 index 2db25a00..00000000 --- a/kassette.cliconfigurationspec.port.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [port](./kassette.cliconfigurationspec.port.md) - -## CLIConfigurationSpec.port property - -The port on which the proxy should listen. Note that kassette accepts both http and https connections on this port. - -**Signature:** - -```typescript -readonly port?: number; -``` - -## Remarks - -If the port is not available, it will fail and stop the program; try again with another, available port. If the port is set to 0, the proxy will listen on a random port (actually depends on the OS implementation): use the callback [onListen](./kassette.configurationspec.onlisten.md) to catch its value. - diff --git a/kassette.cliconfigurationspec.proxyconnectmode.md b/kassette.cliconfigurationspec.proxyconnectmode.md deleted file mode 100644 index 1b1c1856..00000000 --- a/kassette.cliconfigurationspec.proxyconnectmode.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [proxyConnectMode](./kassette.cliconfigurationspec.proxyconnectmode.md) - -## CLIConfigurationSpec.proxyConnectMode property - -Default mode for `CONNECT` requests. - -**Signature:** - -```typescript -readonly proxyConnectMode?: ProxyConnectMode; -``` - -## Remarks - -It can be changed at a request level in the [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) method through [setMode](./kassette.iproxyconnectapi.setmode.md). - diff --git a/kassette.cliconfigurationspec.remoteurl.md b/kassette.cliconfigurationspec.remoteurl.md deleted file mode 100644 index dc4fd071..00000000 --- a/kassette.cliconfigurationspec.remoteurl.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [remoteURL](./kassette.cliconfigurationspec.remoteurl.md) - -## CLIConfigurationSpec.remoteURL property - -The URL of the remote backend, from which only the protocol, hostname and port are used. Can be left `null`, in which case anything leading to sending the request to the remote backend will trigger an exception. Can also contain the special `"*"` value, which means reading from the request the remote backend to target. This is useful when using kassette as a browser proxy. - -**Signature:** - -```typescript -readonly remoteURL?: string | null; -``` - -## Remarks - -It can be changed at a request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setRemoteURL](./kassette.imock.setremoteurl.md). - diff --git a/kassette.cliconfigurationspec.savechecksumcontent.md b/kassette.cliconfigurationspec.savechecksumcontent.md deleted file mode 100644 index 17b3a449..00000000 --- a/kassette.cliconfigurationspec.savechecksumcontent.md +++ /dev/null @@ -1,20 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [saveChecksumContent](./kassette.cliconfigurationspec.savechecksumcontent.md) - -## CLIConfigurationSpec.saveChecksumContent property - -Whether to save the content used to create a checksum when creating a new mock with a checksum. - -**Signature:** - -```typescript -readonly saveChecksumContent?: boolean; -``` - -## Remarks - -The default value of the global `saveChecksumContent` setting is `true`. - -It can be changed at request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setSaveChecksumContent](./kassette.imock.setsavechecksumcontent.md). - diff --git a/kassette.cliconfigurationspec.savedetailedtimings.md b/kassette.cliconfigurationspec.savedetailedtimings.md deleted file mode 100644 index 5769bdc9..00000000 --- a/kassette.cliconfigurationspec.savedetailedtimings.md +++ /dev/null @@ -1,20 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [saveDetailedTimings](./kassette.cliconfigurationspec.savedetailedtimings.md) - -## CLIConfigurationSpec.saveDetailedTimings property - -Whether to save [detailed timings](./kassette.requesttimings.md) when creating a new mock. - -**Signature:** - -```typescript -readonly saveDetailedTimings?: boolean; -``` - -## Remarks - -The default value of the global `saveDetailedTimings` setting is `true`. - -It can be changed at request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setSaveDetailedTimings](./kassette.imock.setsavedetailedtimings.md). - diff --git a/kassette.cliconfigurationspec.saveforwardedrequestbody.md b/kassette.cliconfigurationspec.saveforwardedrequestbody.md deleted file mode 100644 index 0274fee9..00000000 --- a/kassette.cliconfigurationspec.saveforwardedrequestbody.md +++ /dev/null @@ -1,20 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [saveForwardedRequestBody](./kassette.cliconfigurationspec.saveforwardedrequestbody.md) - -## CLIConfigurationSpec.saveForwardedRequestBody property - -Whether to save the forwarded request body when creating a new mock. - -**Signature:** - -```typescript -readonly saveForwardedRequestBody?: boolean | null; -``` - -## Remarks - -The default value of the global `saveForwardedRequestData` setting is `null`, which means `true` when `mocksFormat` is `folder` (for backward-compatibility), and `false` when `mocksFormat` is `har`. - -It can be changed at request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setSaveForwardedRequestBody](./kassette.imock.setsaveforwardedrequestbody.md). - diff --git a/kassette.cliconfigurationspec.saveforwardedrequestdata.md b/kassette.cliconfigurationspec.saveforwardedrequestdata.md deleted file mode 100644 index 2c9c3abb..00000000 --- a/kassette.cliconfigurationspec.saveforwardedrequestdata.md +++ /dev/null @@ -1,20 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [saveForwardedRequestData](./kassette.cliconfigurationspec.saveforwardedrequestdata.md) - -## CLIConfigurationSpec.saveForwardedRequestData property - -Whether to save the forwarded request data (headers, method, URL) when creating a new mock. - -**Signature:** - -```typescript -readonly saveForwardedRequestData?: boolean | null; -``` - -## Remarks - -The default value of the global `saveForwardedRequestData` setting is `null`, which means `true` when `mocksFormat` is `folder` (for backward-compatibility), and `false` when `mocksFormat` is `har`. - -It can be changed at request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setSaveForwardedRequestData](./kassette.imock.setsaveforwardedrequestdata.md). - diff --git a/kassette.cliconfigurationspec.saveinputrequestbody.md b/kassette.cliconfigurationspec.saveinputrequestbody.md deleted file mode 100644 index 184216c5..00000000 --- a/kassette.cliconfigurationspec.saveinputrequestbody.md +++ /dev/null @@ -1,20 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [saveInputRequestBody](./kassette.cliconfigurationspec.saveinputrequestbody.md) - -## CLIConfigurationSpec.saveInputRequestBody property - -Whether to save the content of the input request body when creating a new mock. - -**Signature:** - -```typescript -readonly saveInputRequestBody?: boolean; -``` - -## Remarks - -The default value of the global `saveInputRequestBody` setting is `true`. - -It can be changed at request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setSaveInputRequestBody](./kassette.imock.setsaveinputrequestbody.md). - diff --git a/kassette.cliconfigurationspec.saveinputrequestdata.md b/kassette.cliconfigurationspec.saveinputrequestdata.md deleted file mode 100644 index 5a60c701..00000000 --- a/kassette.cliconfigurationspec.saveinputrequestdata.md +++ /dev/null @@ -1,20 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [saveInputRequestData](./kassette.cliconfigurationspec.saveinputrequestdata.md) - -## CLIConfigurationSpec.saveInputRequestData property - -Whether to save the input request data (headers, method, URL) when creating a new mock. - -**Signature:** - -```typescript -readonly saveInputRequestData?: boolean; -``` - -## Remarks - -The default value of the global `saveInputRequestData` setting is `true`. - -It can be changed at request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setSaveInputRequestData](./kassette.imock.setsaveinputrequestdata.md). - diff --git a/kassette.cliconfigurationspec.skiplog.md b/kassette.cliconfigurationspec.skiplog.md deleted file mode 100644 index fcef28da..00000000 --- a/kassette.cliconfigurationspec.skiplog.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [skipLog](./kassette.cliconfigurationspec.skiplog.md) - -## CLIConfigurationSpec.skipLog property - -If true, will simplify the logging output, logging only one line when the request is received but nothing else afterwards. - -**Signature:** - -```typescript -readonly skipLog?: boolean; -``` diff --git a/kassette.cliconfigurationspec.tlscakeypath.md b/kassette.cliconfigurationspec.tlscakeypath.md deleted file mode 100644 index 9d46cce4..00000000 --- a/kassette.cliconfigurationspec.tlscakeypath.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [tlsCAKeyPath](./kassette.cliconfigurationspec.tlscakeypath.md) - -## CLIConfigurationSpec.tlsCAKeyPath property - -Path to a PEM-encoded CA (Certificate Authority) certificate and key file, created if it does not exist. If not provided, the certificate and key are generated but only kept in memory. This certificate and key are used as needed to sign certificates generated on the fly for any HTTPS connection intercepted by kassette. - -**Signature:** - -```typescript -readonly tlsCAKeyPath?: string | null; -``` - -## Remarks - -You can optionally import in the browser the TLS certificate from this file in order to remove the warning when connecting to HTTPS websites through kassette. - diff --git a/kassette.cliconfigurationspec.tlskeysize.md b/kassette.cliconfigurationspec.tlskeysize.md deleted file mode 100644 index 6a964135..00000000 --- a/kassette.cliconfigurationspec.tlskeysize.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) > [tlsKeySize](./kassette.cliconfigurationspec.tlskeysize.md) - -## CLIConfigurationSpec.tlsKeySize property - -Size in bits of generated RSA keys. - -**Signature:** - -```typescript -readonly tlsKeySize?: number; -``` diff --git a/kassette.configurationpropertysource.md b/kassette.configurationpropertysource.md deleted file mode 100644 index cacea6ce..00000000 --- a/kassette.configurationpropertysource.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConfigurationPropertySource](./kassette.configurationpropertysource.md) - -## ConfigurationPropertySource type - -The id of the source of the resolved value. - -**Signature:** - -```typescript -export type ConfigurationPropertySource = 'cli' | 'file' | 'api' | 'default'; -``` diff --git a/kassette.configurationspec.console.md b/kassette.configurationspec.console.md deleted file mode 100644 index 5368e0eb..00000000 --- a/kassette.configurationspec.console.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConfigurationSpec](./kassette.configurationspec.md) > [console](./kassette.configurationspec.console.md) - -## ConfigurationSpec.console property - -Custom implementation of the [ConsoleSpec](./kassette.consolespec.md) interface, with methods [log](./kassette.consolespec.log.md) and [error](./kassette.consolespec.error.md), each receiving one single argument of any type. Useful to capture the logs of the application. - -**Signature:** - -```typescript -readonly console?: ConsoleSpec; -``` diff --git a/kassette.configurationspec.harmimetypesparsejson.md b/kassette.configurationspec.harmimetypesparsejson.md deleted file mode 100644 index 7187c49c..00000000 --- a/kassette.configurationspec.harmimetypesparsejson.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConfigurationSpec](./kassette.configurationspec.md) > [harMimeTypesParseJson](./kassette.configurationspec.harmimetypesparsejson.md) - -## ConfigurationSpec.harMimeTypesParseJson property - -Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', specifies a list of mime types that will attempt to parse the request/response body as JSON. If the list includes an empty string: '' and there is no mimeType set in the request, it will attempt to parse the body as JSON. This will only be applicable to request bodies if [saveInputRequestBody](./kassette.imock.saveinputrequestbody.md) is set to true Default value will be \[\] and will only be overridden by [setHarMimeTypesParseJson](./kassette.imock.setharmimetypesparsejson.md) - -**Signature:** - -```typescript -readonly harMimeTypesParseJson?: string[]; -``` diff --git a/kassette.configurationspec.hook.md b/kassette.configurationspec.hook.md deleted file mode 100644 index a61e32f5..00000000 --- a/kassette.configurationspec.hook.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConfigurationSpec](./kassette.configurationspec.md) > [hook](./kassette.configurationspec.hook.md) - -## ConfigurationSpec.hook() method - -Callback called for every HTTP request that kassette receives (with the exception of `CONNECT` requests, which trigger the call of [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) instead). - -**Signature:** - -```typescript -hook?(parameters: HookAPI): void | Promise; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| parameters | [HookAPI](./kassette.hookapi.md) | exposes the API to control how to process the request | - -**Returns:** - -void \| Promise<void> - diff --git a/kassette.configurationspec.md b/kassette.configurationspec.md deleted file mode 100644 index 3aa9f1fd..00000000 --- a/kassette.configurationspec.md +++ /dev/null @@ -1,32 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConfigurationSpec](./kassette.configurationspec.md) - -## ConfigurationSpec interface - -Augments the CLI spec to add all pure runtime properties, that can be defined through the configuration file only - -**Signature:** - -```typescript -export interface ConfigurationSpec extends CLIConfigurationSpec -``` -**Extends:** [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [console?](./kassette.configurationspec.console.md) | readonly | [ConsoleSpec](./kassette.consolespec.md) | _(Optional)_ Custom implementation of the [ConsoleSpec](./kassette.consolespec.md) interface, with methods [log](./kassette.consolespec.log.md) and [error](./kassette.consolespec.error.md), each receiving one single argument of any type. Useful to capture the logs of the application. | -| [harMimeTypesParseJson?](./kassette.configurationspec.harmimetypesparsejson.md) | readonly | string\[\] | _(Optional)_ Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', specifies a list of mime types that will attempt to parse the request/response body as JSON. If the list includes an empty string: '' and there is no mimeType set in the request, it will attempt to parse the body as JSON. This will only be applicable to request bodies if [saveInputRequestBody](./kassette.imock.saveinputrequestbody.md) is set to true Default value will be \[\] and will only be overridden by [setHarMimeTypesParseJson](./kassette.imock.setharmimetypesparsejson.md) | -| [mocksHarKeyManager?](./kassette.configurationspec.mocksharkeymanager.md) | readonly | [HarKeyManager](./kassette.harkeymanager.md) | _(Optional)_ Function called to get or set the key of a mock in a har file, as explained in [HarKeyManager](./kassette.harkeymanager.md). | - -## Methods - -| Method | Description | -| --- | --- | -| [hook(parameters)?](./kassette.configurationspec.hook.md) | _(Optional)_ Callback called for every HTTP request that kassette receives (with the exception of CONNECT requests, which trigger the call of [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) instead). | -| [onExit()?](./kassette.configurationspec.onexit.md) | _(Optional)_ Callback called when the proxy is programmatically closed (which can be done by using the callback returned from [runFromAPI()](./kassette.runfromapi.md)) | -| [onListen(parameters)?](./kassette.configurationspec.onlisten.md) | _(Optional)_ Callback called when the proxy is started and listening. | -| [onProxyConnect(parameters)?](./kassette.configurationspec.onproxyconnect.md) | _(Optional)_ Callback called when kassette receives a request with the [HTTP CONNECT method](https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/CONNECT), which usually happens when kassette is used as a browser proxy and the browser is trying to connect to a secure web site with the https protocol. | - diff --git a/kassette.configurationspec.mocksharkeymanager.md b/kassette.configurationspec.mocksharkeymanager.md deleted file mode 100644 index b13d3e56..00000000 --- a/kassette.configurationspec.mocksharkeymanager.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConfigurationSpec](./kassette.configurationspec.md) > [mocksHarKeyManager](./kassette.configurationspec.mocksharkeymanager.md) - -## ConfigurationSpec.mocksHarKeyManager property - -Function called to get or set the key of a mock in a har file, as explained in [HarKeyManager](./kassette.harkeymanager.md). - -**Signature:** - -```typescript -readonly mocksHarKeyManager?: HarKeyManager; -``` - -## Remarks - -It can be changed at a request level in the [hook](./kassette.configurationspec.hook.md) method through [mock.setMocksHarKeyManager](./kassette.imock.setmocksharkeymanager.md). - diff --git a/kassette.configurationspec.onexit.md b/kassette.configurationspec.onexit.md deleted file mode 100644 index f4bd0a5b..00000000 --- a/kassette.configurationspec.onexit.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConfigurationSpec](./kassette.configurationspec.md) > [onExit](./kassette.configurationspec.onexit.md) - -## ConfigurationSpec.onExit() method - -Callback called when the proxy is programmatically closed (which can be done by using the callback returned from [runFromAPI()](./kassette.runfromapi.md)) - -**Signature:** - -```typescript -onExit?(): void; -``` -**Returns:** - -void - diff --git a/kassette.configurationspec.onlisten.md b/kassette.configurationspec.onlisten.md deleted file mode 100644 index d157cb42..00000000 --- a/kassette.configurationspec.onlisten.md +++ /dev/null @@ -1,26 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConfigurationSpec](./kassette.configurationspec.md) > [onListen](./kassette.configurationspec.onlisten.md) - -## ConfigurationSpec.onListen() method - -Callback called when the proxy is started and listening. - -**Signature:** - -```typescript -onListen?(parameters: { - port: number; - }): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| parameters | { port: number; } | the port property contains the port on which the proxy is listening. | - -**Returns:** - -void - diff --git a/kassette.configurationspec.onproxyconnect.md b/kassette.configurationspec.onproxyconnect.md deleted file mode 100644 index 36591977..00000000 --- a/kassette.configurationspec.onproxyconnect.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConfigurationSpec](./kassette.configurationspec.md) > [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) - -## ConfigurationSpec.onProxyConnect() method - -Callback called when kassette receives a request with the [HTTP CONNECT method](https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/CONNECT), which usually happens when kassette is used as a browser proxy and the browser is trying to connect to a secure web site with the https protocol. - -**Signature:** - -```typescript -onProxyConnect?(parameters: IProxyConnectAPI): void | Promise; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| parameters | [IProxyConnectAPI](./kassette.iproxyconnectapi.md) | exposes the API to control how to process the request | - -**Returns:** - -void \| Promise<void> - diff --git a/kassette.connection.hostname.md b/kassette.connection.hostname.md deleted file mode 100644 index 7df185b5..00000000 --- a/kassette.connection.hostname.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Connection](./kassette.connection.md) > [hostname](./kassette.connection.hostname.md) - -## Connection.hostname property - -target hostname - -**Signature:** - -```typescript -hostname: string; -``` diff --git a/kassette.connection.md b/kassette.connection.md deleted file mode 100644 index 7c1112fd..00000000 --- a/kassette.connection.md +++ /dev/null @@ -1,22 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Connection](./kassette.connection.md) - -## Connection interface - -A connection intercepted by kassette - -**Signature:** - -```typescript -export interface Connection -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [hostname](./kassette.connection.hostname.md) | | string | target hostname | -| [port](./kassette.connection.port.md) | | number | target port | -| [protocol](./kassette.connection.protocol.md) | | string | protocol such as http or https, without the trailing : | - diff --git a/kassette.connection.port.md b/kassette.connection.port.md deleted file mode 100644 index 035f0223..00000000 --- a/kassette.connection.port.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Connection](./kassette.connection.md) > [port](./kassette.connection.port.md) - -## Connection.port property - -target port - -**Signature:** - -```typescript -port: number; -``` diff --git a/kassette.connection.protocol.md b/kassette.connection.protocol.md deleted file mode 100644 index 314d3ae6..00000000 --- a/kassette.connection.protocol.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Connection](./kassette.connection.md) > [protocol](./kassette.connection.protocol.md) - -## Connection.protocol property - -protocol such as `http` or `https`, without the trailing `:` - -**Signature:** - -```typescript -protocol: string; -``` diff --git a/kassette.consolespec.error.md b/kassette.consolespec.error.md deleted file mode 100644 index b0dcd898..00000000 --- a/kassette.consolespec.error.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConsoleSpec](./kassette.consolespec.md) > [error](./kassette.consolespec.error.md) - -## ConsoleSpec.error() method - -Logs an error message. - -**Signature:** - -```typescript -error(message: any): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| message | any | error message to log | - -**Returns:** - -void - diff --git a/kassette.consolespec.log.md b/kassette.consolespec.log.md deleted file mode 100644 index fcd4b9b0..00000000 --- a/kassette.consolespec.log.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConsoleSpec](./kassette.consolespec.md) > [log](./kassette.consolespec.log.md) - -## ConsoleSpec.log() method - -Logs a message. - -**Signature:** - -```typescript -log(message: any): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| message | any | message to log | - -**Returns:** - -void - diff --git a/kassette.consolespec.md b/kassette.consolespec.md deleted file mode 100644 index 8b91a6be..00000000 --- a/kassette.consolespec.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ConsoleSpec](./kassette.consolespec.md) - -## ConsoleSpec interface - -Console with logging methods. - -**Signature:** - -```typescript -export interface ConsoleSpec -``` - -## Methods - -| Method | Description | -| --- | --- | -| [error(message)](./kassette.consolespec.error.md) | Logs an error message. | -| [log(message)](./kassette.consolespec.log.md) | Logs a message. | - diff --git a/kassette.delay.md b/kassette.delay.md deleted file mode 100644 index 24471932..00000000 --- a/kassette.delay.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Delay](./kassette.delay.md) - -## Delay type - -Delay that will be used to send the response to the client when the data is taken from the local mock. - -**Signature:** - -```typescript -export type Delay = 'recorded' | number; -``` - -## Remarks - -It can be expressed either as a direct value (in milliseconds) or as the `'recorded'` string, which means to use the delay recorded in the local mock (in the [time](./kassette.mockdata.time.md) field). - diff --git a/kassette.filterablespec.filter.md b/kassette.filterablespec.filter.md deleted file mode 100644 index 075bfed8..00000000 --- a/kassette.filterablespec.filter.md +++ /dev/null @@ -1,26 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [FilterableSpec](./kassette.filterablespec.md) > [filter](./kassette.filterablespec.filter.md) - -## FilterableSpec.filter() method - -A function used to filter (i.e. modify) the piece of data before it is included in the hash. If no function is given, the unmodified piece of data is used. - -**Signature:** - -```typescript -filter?(input: I): O | Promise; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| input | I | piece of data to filter | - -**Returns:** - -O \| Promise<O> - -The modified piece of data. Note that the filter function can optionally be asynchronous, in which case it is expected to return a promise of the modified piece of data. - diff --git a/kassette.filterablespec.md b/kassette.filterablespec.md deleted file mode 100644 index faff9851..00000000 --- a/kassette.filterablespec.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [FilterableSpec](./kassette.filterablespec.md) - -## FilterableSpec interface - -Interface used in [ChecksumArgs](./kassette.checksumargs.md) for each piece of data that can be filtered (i.e. modified) before it is included in the hash computed by the [checksum](./kassette.imock.checksum.md) method. - -**Signature:** - -```typescript -export interface FilterableSpec extends IncludableSpec -``` -**Extends:** [IncludableSpec](./kassette.includablespec.md) - -## Methods - -| Method | Description | -| --- | --- | -| [filter(input)?](./kassette.filterablespec.filter.md) | _(Optional)_ A function used to filter (i.e. modify) the piece of data before it is included in the hash. If no function is given, the unmodified piece of data is used. | - diff --git a/kassette.getconfigurationprops.apiconfiguration.md b/kassette.getconfigurationprops.apiconfiguration.md deleted file mode 100644 index 2ead74c8..00000000 --- a/kassette.getconfigurationprops.apiconfiguration.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [GetConfigurationProps](./kassette.getconfigurationprops.md) > [apiConfiguration](./kassette.getconfigurationprops.apiconfiguration.md) - -## GetConfigurationProps.apiConfiguration property - -If run from the API, this is the configuration coming from the [runFromAPI()](./kassette.runfromapi.md) call. Otherwise it is an empty object. - -**Signature:** - -```typescript -apiConfiguration: ConfigurationSpec; -``` diff --git a/kassette.getconfigurationprops.cliconfiguration.md b/kassette.getconfigurationprops.cliconfiguration.md deleted file mode 100644 index ea586719..00000000 --- a/kassette.getconfigurationprops.cliconfiguration.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [GetConfigurationProps](./kassette.getconfigurationprops.md) > [cliConfiguration](./kassette.getconfigurationprops.cliconfiguration.md) - -## GetConfigurationProps.cliConfiguration property - -If run from the CLI, this is the configuration coming from the CLI. Otherwise it is an empty object. - -**Signature:** - -```typescript -cliConfiguration: CLIConfigurationSpec; -``` diff --git a/kassette.getconfigurationprops.context.md b/kassette.getconfigurationprops.context.md deleted file mode 100644 index 58f803db..00000000 --- a/kassette.getconfigurationprops.context.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [GetConfigurationProps](./kassette.getconfigurationprops.md) > [context](./kassette.getconfigurationprops.context.md) - -## GetConfigurationProps.context property - -If run from the API, this is the context value provided (if any) through [runFromAPI()](./kassette.runfromapi.md). Otherwise it is undefined. - -**Signature:** - -```typescript -context: any; -``` diff --git a/kassette.getconfigurationprops.md b/kassette.getconfigurationprops.md deleted file mode 100644 index c62d9682..00000000 --- a/kassette.getconfigurationprops.md +++ /dev/null @@ -1,22 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [GetConfigurationProps](./kassette.getconfigurationprops.md) - -## GetConfigurationProps interface - -Parameter of the [getConfiguration](./kassette.iconfigurationfile.getconfiguration.md) function (which a kassette configuration file is supposed to export). - -**Signature:** - -```typescript -export interface GetConfigurationProps -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [apiConfiguration](./kassette.getconfigurationprops.apiconfiguration.md) | | [ConfigurationSpec](./kassette.configurationspec.md) | If run from the API, this is the configuration coming from the [runFromAPI()](./kassette.runfromapi.md) call. Otherwise it is an empty object. | -| [cliConfiguration](./kassette.getconfigurationprops.cliconfiguration.md) | | [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) | If run from the CLI, this is the configuration coming from the CLI. Otherwise it is an empty object. | -| [context](./kassette.getconfigurationprops.context.md) | | any | If run from the API, this is the context value provided (if any) through [runFromAPI()](./kassette.runfromapi.md). Otherwise it is undefined. | - diff --git a/kassette.harformatcontent.comment.md b/kassette.harformatcontent.comment.md deleted file mode 100644 index 61547160..00000000 --- a/kassette.harformatcontent.comment.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatContent](./kassette.harformatcontent.md) > [comment](./kassette.harformatcontent.comment.md) - -## HarFormatContent.comment property - -Any comment as a string. This is not used by kassette. - -**Signature:** - -```typescript -comment?: string; -``` diff --git a/kassette.harformatcontent.compression.md b/kassette.harformatcontent.compression.md deleted file mode 100644 index 6c62041d..00000000 --- a/kassette.harformatcontent.compression.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatContent](./kassette.harformatcontent.md) > [compression](./kassette.harformatcontent.compression.md) - -## HarFormatContent.compression property - -Number of bytes saved by compression. This is not implemented by kassette. - -**Signature:** - -```typescript -compression?: number; -``` diff --git a/kassette.harformatcontent.encoding.md b/kassette.harformatcontent.encoding.md deleted file mode 100644 index 064a7a72..00000000 --- a/kassette.harformatcontent.encoding.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatContent](./kassette.harformatcontent.md) > [encoding](./kassette.harformatcontent.encoding.md) - -## HarFormatContent.encoding property - -Encoding used for the [text](./kassette.harformatcontent.text.md) field, such as "base64". - -**Signature:** - -```typescript -encoding?: string; -``` diff --git a/kassette.harformatcontent.json.md b/kassette.harformatcontent.json.md deleted file mode 100644 index 3b5b3106..00000000 --- a/kassette.harformatcontent.json.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatContent](./kassette.harformatcontent.md) > [json](./kassette.harformatcontent.json.md) - -## HarFormatContent.json property - -Response body saved as an object. - -**Signature:** - -```typescript -json?: any; -``` diff --git a/kassette.harformatcontent.md b/kassette.harformatcontent.md deleted file mode 100644 index 460f0d3c..00000000 --- a/kassette.harformatcontent.md +++ /dev/null @@ -1,26 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatContent](./kassette.harformatcontent.md) - -## HarFormatContent interface - -Information about the response body, as stored in a har file. - -**Signature:** - -```typescript -export interface HarFormatContent -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [comment?](./kassette.harformatcontent.comment.md) | | string | _(Optional)_ Any comment as a string. This is not used by kassette. | -| [compression?](./kassette.harformatcontent.compression.md) | | number | _(Optional)_ Number of bytes saved by compression. This is not implemented by kassette. | -| [encoding?](./kassette.harformatcontent.encoding.md) | | string | _(Optional)_ Encoding used for the [text](./kassette.harformatcontent.text.md) field, such as "base64". | -| [json?](./kassette.harformatcontent.json.md) | | any | _(Optional)_ Response body saved as an object. | -| [mimeType?](./kassette.harformatcontent.mimetype.md) | | string | _(Optional)_ Value of the Content-Type response header. | -| [size?](./kassette.harformatcontent.size.md) | | number | _(Optional)_ Size of the content in bytes. | -| [text?](./kassette.harformatcontent.text.md) | | string | _(Optional)_ Response body. | - diff --git a/kassette.harformatcontent.mimetype.md b/kassette.harformatcontent.mimetype.md deleted file mode 100644 index 35182113..00000000 --- a/kassette.harformatcontent.mimetype.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatContent](./kassette.harformatcontent.md) > [mimeType](./kassette.harformatcontent.mimetype.md) - -## HarFormatContent.mimeType property - -Value of the `Content-Type` response header. - -**Signature:** - -```typescript -mimeType?: string; -``` diff --git a/kassette.harformatcontent.size.md b/kassette.harformatcontent.size.md deleted file mode 100644 index 6c7e7fe5..00000000 --- a/kassette.harformatcontent.size.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatContent](./kassette.harformatcontent.md) > [size](./kassette.harformatcontent.size.md) - -## HarFormatContent.size property - -Size of the content in bytes. - -**Signature:** - -```typescript -size?: number; -``` diff --git a/kassette.harformatcontent.text.md b/kassette.harformatcontent.text.md deleted file mode 100644 index afbf9d71..00000000 --- a/kassette.harformatcontent.text.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatContent](./kassette.harformatcontent.md) > [text](./kassette.harformatcontent.text.md) - -## HarFormatContent.text property - -Response body. - -**Signature:** - -```typescript -text?: string; -``` - -## Remarks - -The response body can be encoded in base64 if this is specified in the [encoding](./kassette.harformatcontent.encoding.md) field. - diff --git a/kassette.harformatentry._kassettechecksumcontent.md b/kassette.harformatentry._kassettechecksumcontent.md deleted file mode 100644 index d5d04ec3..00000000 --- a/kassette.harformatentry._kassettechecksumcontent.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [\_kassetteChecksumContent](./kassette.harformatentry._kassettechecksumcontent.md) - -## HarFormatEntry.\_kassetteChecksumContent property - -Content used to create a checksum - -**Signature:** - -```typescript -_kassetteChecksumContent?: string; -``` - -## Remarks - -kassette only includes this field if [saveChecksumContent](./kassette.imock.savechecksumcontent.md) is true and if the [checksum](./kassette.imock.checksum.md) method was called. - diff --git a/kassette.harformatentry._kassetteforwardedrequest.md b/kassette.harformatentry._kassetteforwardedrequest.md deleted file mode 100644 index 486abe7c..00000000 --- a/kassette.harformatentry._kassetteforwardedrequest.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [\_kassetteForwardedRequest](./kassette.harformatentry._kassetteforwardedrequest.md) - -## HarFormatEntry.\_kassetteForwardedRequest property - -Detailed information about the request forwarded to the remote server. - -**Signature:** - -```typescript -_kassetteForwardedRequest?: HarFormatRequest; -``` - -## Remarks - -kassette only includes this field if [saveInputRequestData](./kassette.imock.saveforwardedrequestdata.md) is true. - diff --git a/kassette.harformatentry._kassettemockkey.md b/kassette.harformatentry._kassettemockkey.md deleted file mode 100644 index 20f17a35..00000000 --- a/kassette.harformatentry._kassettemockkey.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [\_kassetteMockKey](./kassette.harformatentry._kassettemockkey.md) - -## HarFormatEntry.\_kassetteMockKey property - -Key used by kassette to select the correct mock to replay. - -**Signature:** - -```typescript -_kassetteMockKey?: string; -``` - -## Remarks - -This field contains the value passed to [IMock.setMockHarKey()](./kassette.imock.setmockharkey.md) when used with the default [mocksHarKeyManager](./kassette.configurationspec.mocksharkeymanager.md). - diff --git a/kassette.harformatentry.cache.md b/kassette.harformatentry.cache.md deleted file mode 100644 index 2a414a5d..00000000 --- a/kassette.harformatentry.cache.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [cache](./kassette.harformatentry.cache.md) - -## HarFormatEntry.cache property - -Information about the cache. This is not implemented in kassette. - -**Signature:** - -```typescript -cache?: any; -``` diff --git a/kassette.harformatentry.comment.md b/kassette.harformatentry.comment.md deleted file mode 100644 index 979adf08..00000000 --- a/kassette.harformatentry.comment.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [comment](./kassette.harformatentry.comment.md) - -## HarFormatEntry.comment property - -Any comment as a string. This is not used by kassette. - -**Signature:** - -```typescript -comment?: string; -``` diff --git a/kassette.harformatentry.connection.md b/kassette.harformatentry.connection.md deleted file mode 100644 index f44f5bab..00000000 --- a/kassette.harformatentry.connection.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [connection](./kassette.harformatentry.connection.md) - -## HarFormatEntry.connection property - -Unique ID of the TCP/IP connection. This is not implemented in kassette. - -**Signature:** - -```typescript -connection?: string; -``` diff --git a/kassette.harformatentry.md b/kassette.harformatentry.md deleted file mode 100644 index ced7c8a1..00000000 --- a/kassette.harformatentry.md +++ /dev/null @@ -1,32 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) - -## HarFormatEntry interface - -Detailed information about a request and its response, as stored in a har file. - -**Signature:** - -```typescript -export interface HarFormatEntry -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [\_kassetteChecksumContent?](./kassette.harformatentry._kassettechecksumcontent.md) | | string | _(Optional)_ Content used to create a checksum | -| [\_kassetteForwardedRequest?](./kassette.harformatentry._kassetteforwardedrequest.md) | | [HarFormatRequest](./kassette.harformatrequest.md) | _(Optional)_ Detailed information about the request forwarded to the remote server. | -| [\_kassetteMockKey?](./kassette.harformatentry._kassettemockkey.md) | | string | _(Optional)_ Key used by kassette to select the correct mock to replay. | -| [cache?](./kassette.harformatentry.cache.md) | | any | _(Optional)_ Information about the cache. This is not implemented in kassette. | -| [comment?](./kassette.harformatentry.comment.md) | | string | _(Optional)_ Any comment as a string. This is not used by kassette. | -| [connection?](./kassette.harformatentry.connection.md) | | string | _(Optional)_ Unique ID of the TCP/IP connection. This is not implemented in kassette. | -| [pageref?](./kassette.harformatentry.pageref.md) | | string | _(Optional)_ Reference to the parent page. This is not implemented in kassette. | -| [request?](./kassette.harformatentry.request.md) | | [HarFormatRequest](./kassette.harformatrequest.md) | _(Optional)_ Detailed information about the input request. | -| [response?](./kassette.harformatentry.response.md) | | [HarFormatResponse](./kassette.harformatresponse.md) | _(Optional)_ Detailed information about the response. | -| [serverIPAddress?](./kassette.harformatentry.serveripaddress.md) | | string | _(Optional)_ Server IP address. This is not implemented in kassette. | -| [startedDateTime?](./kassette.harformatentry.starteddatetime.md) | | string | _(Optional)_ Date and time of the request start, as a string in ISO format (YYYY-MM-DDThh:mm:ss.sTZD). | -| [time?](./kassette.harformatentry.time.md) | | number | _(Optional)_ Total time of the request, in milliseconds. This is the sum of all timings in the [timings object](./kassette.harformatentry.timings.md). | -| [timings?](./kassette.harformatentry.timings.md) | | [HarFormatTimings](./kassette.harformattimings.md) | _(Optional)_ Detailed timing information about request/response round trip. | - diff --git a/kassette.harformatentry.pageref.md b/kassette.harformatentry.pageref.md deleted file mode 100644 index 7b334845..00000000 --- a/kassette.harformatentry.pageref.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [pageref](./kassette.harformatentry.pageref.md) - -## HarFormatEntry.pageref property - -Reference to the parent page. This is not implemented in kassette. - -**Signature:** - -```typescript -pageref?: string; -``` diff --git a/kassette.harformatentry.request.md b/kassette.harformatentry.request.md deleted file mode 100644 index 00277b1a..00000000 --- a/kassette.harformatentry.request.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [request](./kassette.harformatentry.request.md) - -## HarFormatEntry.request property - -Detailed information about the input request. - -**Signature:** - -```typescript -request?: HarFormatRequest; -``` - -## Remarks - -kassette only includes this field if [saveInputRequestData](./kassette.imock.saveinputrequestdata.md) is true. - diff --git a/kassette.harformatentry.response.md b/kassette.harformatentry.response.md deleted file mode 100644 index 7ebefdc4..00000000 --- a/kassette.harformatentry.response.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [response](./kassette.harformatentry.response.md) - -## HarFormatEntry.response property - -Detailed information about the response. - -**Signature:** - -```typescript -response?: HarFormatResponse; -``` diff --git a/kassette.harformatentry.serveripaddress.md b/kassette.harformatentry.serveripaddress.md deleted file mode 100644 index a3579b97..00000000 --- a/kassette.harformatentry.serveripaddress.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [serverIPAddress](./kassette.harformatentry.serveripaddress.md) - -## HarFormatEntry.serverIPAddress property - -Server IP address. This is not implemented in kassette. - -**Signature:** - -```typescript -serverIPAddress?: string; -``` diff --git a/kassette.harformatentry.starteddatetime.md b/kassette.harformatentry.starteddatetime.md deleted file mode 100644 index 248d87a0..00000000 --- a/kassette.harformatentry.starteddatetime.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [startedDateTime](./kassette.harformatentry.starteddatetime.md) - -## HarFormatEntry.startedDateTime property - -Date and time of the request start, as a string in ISO format (YYYY-MM-DDThh:mm:ss.sTZD). - -**Signature:** - -```typescript -startedDateTime?: string; -``` diff --git a/kassette.harformatentry.time.md b/kassette.harformatentry.time.md deleted file mode 100644 index 970f2c77..00000000 --- a/kassette.harformatentry.time.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [time](./kassette.harformatentry.time.md) - -## HarFormatEntry.time property - -Total time of the request, in milliseconds. This is the sum of all timings in the [timings object](./kassette.harformatentry.timings.md). - -**Signature:** - -```typescript -time?: number; -``` diff --git a/kassette.harformatentry.timings.md b/kassette.harformatentry.timings.md deleted file mode 100644 index d63bec37..00000000 --- a/kassette.harformatentry.timings.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatEntry](./kassette.harformatentry.md) > [timings](./kassette.harformatentry.timings.md) - -## HarFormatEntry.timings property - -Detailed timing information about request/response round trip. - -**Signature:** - -```typescript -timings?: HarFormatTimings; -``` - -## Remarks - -kassette only includes this field if [saveDetailedTimings](./kassette.imock.savedetailedtimings.md) is true. - diff --git a/kassette.harformatnamevaluepair.comment.md b/kassette.harformatnamevaluepair.comment.md deleted file mode 100644 index 5e1c10ce..00000000 --- a/kassette.harformatnamevaluepair.comment.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatNameValuePair](./kassette.harformatnamevaluepair.md) > [comment](./kassette.harformatnamevaluepair.comment.md) - -## HarFormatNameValuePair.comment property - -Any comment as a string. This is not used by kassette. - -**Signature:** - -```typescript -comment?: string; -``` diff --git a/kassette.harformatnamevaluepair.md b/kassette.harformatnamevaluepair.md deleted file mode 100644 index 96f53cfb..00000000 --- a/kassette.harformatnamevaluepair.md +++ /dev/null @@ -1,22 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatNameValuePair](./kassette.harformatnamevaluepair.md) - -## HarFormatNameValuePair interface - -Information about a header or a query parameter, as stored in a har file. - -**Signature:** - -```typescript -export interface HarFormatNameValuePair -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [comment?](./kassette.harformatnamevaluepair.comment.md) | | string | _(Optional)_ Any comment as a string. This is not used by kassette. | -| [name](./kassette.harformatnamevaluepair.name.md) | | string | Name of the header or query parameter. | -| [value](./kassette.harformatnamevaluepair.value.md) | | string | Value of the header or the query parameter. | - diff --git a/kassette.harformatnamevaluepair.name.md b/kassette.harformatnamevaluepair.name.md deleted file mode 100644 index 232d8423..00000000 --- a/kassette.harformatnamevaluepair.name.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatNameValuePair](./kassette.harformatnamevaluepair.md) > [name](./kassette.harformatnamevaluepair.name.md) - -## HarFormatNameValuePair.name property - -Name of the header or query parameter. - -**Signature:** - -```typescript -name: string; -``` diff --git a/kassette.harformatnamevaluepair.value.md b/kassette.harformatnamevaluepair.value.md deleted file mode 100644 index e06046e2..00000000 --- a/kassette.harformatnamevaluepair.value.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatNameValuePair](./kassette.harformatnamevaluepair.md) > [value](./kassette.harformatnamevaluepair.value.md) - -## HarFormatNameValuePair.value property - -Value of the header or the query parameter. - -**Signature:** - -```typescript -value: string; -``` diff --git a/kassette.harformatpostdata.comment.md b/kassette.harformatpostdata.comment.md deleted file mode 100644 index dbb42ce4..00000000 --- a/kassette.harformatpostdata.comment.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatPostData](./kassette.harformatpostdata.md) > [comment](./kassette.harformatpostdata.comment.md) - -## HarFormatPostData.comment property - -Any comment as a string. This is not used by kassette. - -**Signature:** - -```typescript -comment?: string; -``` diff --git a/kassette.harformatpostdata.json.md b/kassette.harformatpostdata.json.md deleted file mode 100644 index 7b0b8dc1..00000000 --- a/kassette.harformatpostdata.json.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatPostData](./kassette.harformatpostdata.md) > [json](./kassette.harformatpostdata.json.md) - -## HarFormatPostData.json property - -Response body saved as an object. - -**Signature:** - -```typescript -json?: any; -``` diff --git a/kassette.harformatpostdata.md b/kassette.harformatpostdata.md deleted file mode 100644 index 77809f15..00000000 --- a/kassette.harformatpostdata.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatPostData](./kassette.harformatpostdata.md) - -## HarFormatPostData interface - -Information about a request body, as stored in a har file. - -**Signature:** - -```typescript -export interface HarFormatPostData -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [comment?](./kassette.harformatpostdata.comment.md) | | string | _(Optional)_ Any comment as a string. This is not used by kassette. | -| [json?](./kassette.harformatpostdata.json.md) | | any | _(Optional)_ Response body saved as an object. | -| [mimeType?](./kassette.harformatpostdata.mimetype.md) | | string | _(Optional)_ Value of the Content-Type request header, if present. | -| [params?](./kassette.harformatpostdata.params.md) | | any\[\] | _(Optional)_ List of posted parameters. This is not implemented in kassette. | -| [text?](./kassette.harformatpostdata.text.md) | | string | _(Optional)_ Posted data, as a (binary) string. | - diff --git a/kassette.harformatpostdata.mimetype.md b/kassette.harformatpostdata.mimetype.md deleted file mode 100644 index fdee79b3..00000000 --- a/kassette.harformatpostdata.mimetype.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatPostData](./kassette.harformatpostdata.md) > [mimeType](./kassette.harformatpostdata.mimetype.md) - -## HarFormatPostData.mimeType property - -Value of the `Content-Type` request header, if present. - -**Signature:** - -```typescript -mimeType?: string; -``` diff --git a/kassette.harformatpostdata.params.md b/kassette.harformatpostdata.params.md deleted file mode 100644 index 1471f0e9..00000000 --- a/kassette.harformatpostdata.params.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatPostData](./kassette.harformatpostdata.md) > [params](./kassette.harformatpostdata.params.md) - -## HarFormatPostData.params property - -List of posted parameters. This is not implemented in kassette. - -**Signature:** - -```typescript -params?: any[]; -``` - -## Remarks - -kassette always fills the [text field](./kassette.harformatpostdata.text.md) and never uses the params field. - diff --git a/kassette.harformatpostdata.text.md b/kassette.harformatpostdata.text.md deleted file mode 100644 index 442b08ee..00000000 --- a/kassette.harformatpostdata.text.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatPostData](./kassette.harformatpostdata.md) > [text](./kassette.harformatpostdata.text.md) - -## HarFormatPostData.text property - -Posted data, as a (binary) string. - -**Signature:** - -```typescript -text?: string; -``` diff --git a/kassette.harformatrequest.bodysize.md b/kassette.harformatrequest.bodysize.md deleted file mode 100644 index f83d00b5..00000000 --- a/kassette.harformatrequest.bodysize.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) > [bodySize](./kassette.harformatrequest.bodysize.md) - -## HarFormatRequest.bodySize property - -Size of the request body in bytes or -1 if it is unknown. - -**Signature:** - -```typescript -bodySize?: number; -``` diff --git a/kassette.harformatrequest.comment.md b/kassette.harformatrequest.comment.md deleted file mode 100644 index 0319e7b4..00000000 --- a/kassette.harformatrequest.comment.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) > [comment](./kassette.harformatrequest.comment.md) - -## HarFormatRequest.comment property - -Any comment as a string. This is not used by kassette. - -**Signature:** - -```typescript -comment?: string; -``` diff --git a/kassette.harformatrequest.cookies.md b/kassette.harformatrequest.cookies.md deleted file mode 100644 index 3e3b8222..00000000 --- a/kassette.harformatrequest.cookies.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) > [cookies](./kassette.harformatrequest.cookies.md) - -## HarFormatRequest.cookies property - -Information about cookies. This is not implemented in kassette. - -**Signature:** - -```typescript -cookies?: any[]; -``` diff --git a/kassette.harformatrequest.headers.md b/kassette.harformatrequest.headers.md deleted file mode 100644 index 3b42f86e..00000000 --- a/kassette.harformatrequest.headers.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) > [headers](./kassette.harformatrequest.headers.md) - -## HarFormatRequest.headers property - -List of request headers. - -**Signature:** - -```typescript -headers?: HarFormatNameValuePair[]; -``` diff --git a/kassette.harformatrequest.headerssize.md b/kassette.harformatrequest.headerssize.md deleted file mode 100644 index db65d6e6..00000000 --- a/kassette.harformatrequest.headerssize.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) > [headersSize](./kassette.harformatrequest.headerssize.md) - -## HarFormatRequest.headersSize property - -Total number of bytes from the start of the HTTP request message until (and including) the double CRLF before the body, or -1 if it is unknown. kassette always sets -1 for this field. - -**Signature:** - -```typescript -headersSize?: number; -``` diff --git a/kassette.harformatrequest.httpversion.md b/kassette.harformatrequest.httpversion.md deleted file mode 100644 index c9b43866..00000000 --- a/kassette.harformatrequest.httpversion.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) > [httpVersion](./kassette.harformatrequest.httpversion.md) - -## HarFormatRequest.httpVersion property - -Request HTTP version, such as "HTTP/1.1". - -**Signature:** - -```typescript -httpVersion?: string; -``` diff --git a/kassette.harformatrequest.md b/kassette.harformatrequest.md deleted file mode 100644 index 17667fc8..00000000 --- a/kassette.harformatrequest.md +++ /dev/null @@ -1,29 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) - -## HarFormatRequest interface - -Detailed information about a request, as stored in a har file. - -**Signature:** - -```typescript -export interface HarFormatRequest -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [bodySize?](./kassette.harformatrequest.bodysize.md) | | number | _(Optional)_ Size of the request body in bytes or -1 if it is unknown. | -| [comment?](./kassette.harformatrequest.comment.md) | | string | _(Optional)_ Any comment as a string. This is not used by kassette. | -| [cookies?](./kassette.harformatrequest.cookies.md) | | any\[\] | _(Optional)_ Information about cookies. This is not implemented in kassette. | -| [headers?](./kassette.harformatrequest.headers.md) | | [HarFormatNameValuePair](./kassette.harformatnamevaluepair.md)\[\] | _(Optional)_ List of request headers. | -| [headersSize?](./kassette.harformatrequest.headerssize.md) | | number | _(Optional)_ Total number of bytes from the start of the HTTP request message until (and including) the double CRLF before the body, or -1 if it is unknown. kassette always sets -1 for this field. | -| [httpVersion?](./kassette.harformatrequest.httpversion.md) | | string | _(Optional)_ Request HTTP version, such as "HTTP/1.1". | -| [method?](./kassette.harformatrequest.method.md) | | string | _(Optional)_ Request method, such as "GET" or "POST". | -| [postData?](./kassette.harformatrequest.postdata.md) | | [HarFormatPostData](./kassette.harformatpostdata.md) | _(Optional)_ Information about the request body. | -| [queryString?](./kassette.harformatrequest.querystring.md) | | [HarFormatNameValuePair](./kassette.harformatnamevaluepair.md)\[\] | _(Optional)_ List of query parameters. | -| [url?](./kassette.harformatrequest.url.md) | | string | _(Optional)_ Request URL. | - diff --git a/kassette.harformatrequest.method.md b/kassette.harformatrequest.method.md deleted file mode 100644 index 1a0d8d79..00000000 --- a/kassette.harformatrequest.method.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) > [method](./kassette.harformatrequest.method.md) - -## HarFormatRequest.method property - -Request method, such as "GET" or "POST". - -**Signature:** - -```typescript -method?: string; -``` diff --git a/kassette.harformatrequest.postdata.md b/kassette.harformatrequest.postdata.md deleted file mode 100644 index 603ce4e6..00000000 --- a/kassette.harformatrequest.postdata.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) > [postData](./kassette.harformatrequest.postdata.md) - -## HarFormatRequest.postData property - -Information about the request body. - -**Signature:** - -```typescript -postData?: HarFormatPostData; -``` - -## Remarks - -kassette only includes this field if [saveInputRequestBody](./kassette.imock.saveinputrequestbody.md) is true (or, for the [\_kassetteForwardedRequest](./kassette.harformatentry._kassetteforwardedrequest.md).postData field, if [saveForwardedRequestBody](./kassette.imock.saveforwardedrequestbody.md) is true). - diff --git a/kassette.harformatrequest.querystring.md b/kassette.harformatrequest.querystring.md deleted file mode 100644 index f0a30f82..00000000 --- a/kassette.harformatrequest.querystring.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) > [queryString](./kassette.harformatrequest.querystring.md) - -## HarFormatRequest.queryString property - -List of query parameters. - -**Signature:** - -```typescript -queryString?: HarFormatNameValuePair[]; -``` diff --git a/kassette.harformatrequest.url.md b/kassette.harformatrequest.url.md deleted file mode 100644 index 303715bd..00000000 --- a/kassette.harformatrequest.url.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatRequest](./kassette.harformatrequest.md) > [url](./kassette.harformatrequest.url.md) - -## HarFormatRequest.url property - -Request URL. - -**Signature:** - -```typescript -url?: string; -``` diff --git a/kassette.harformatresponse.bodysize.md b/kassette.harformatresponse.bodysize.md deleted file mode 100644 index 8d3f45d1..00000000 --- a/kassette.harformatresponse.bodysize.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) > [bodySize](./kassette.harformatresponse.bodysize.md) - -## HarFormatResponse.bodySize property - -Size of the response body in bytes, or -1 if it is unknown. - -**Signature:** - -```typescript -bodySize?: number; -``` diff --git a/kassette.harformatresponse.comment.md b/kassette.harformatresponse.comment.md deleted file mode 100644 index 27bc3e49..00000000 --- a/kassette.harformatresponse.comment.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) > [comment](./kassette.harformatresponse.comment.md) - -## HarFormatResponse.comment property - -Any comment as a string. This is not used by kassette. - -**Signature:** - -```typescript -comment?: string; -``` diff --git a/kassette.harformatresponse.content.md b/kassette.harformatresponse.content.md deleted file mode 100644 index ae4fba2e..00000000 --- a/kassette.harformatresponse.content.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) > [content](./kassette.harformatresponse.content.md) - -## HarFormatResponse.content property - -Information about the response body. - -**Signature:** - -```typescript -content?: HarFormatContent; -``` diff --git a/kassette.harformatresponse.cookies.md b/kassette.harformatresponse.cookies.md deleted file mode 100644 index 1be8716c..00000000 --- a/kassette.harformatresponse.cookies.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) > [cookies](./kassette.harformatresponse.cookies.md) - -## HarFormatResponse.cookies property - -Information about cookies. This is not implemented in kassette. - -**Signature:** - -```typescript -cookies?: any[]; -``` diff --git a/kassette.harformatresponse.headers.md b/kassette.harformatresponse.headers.md deleted file mode 100644 index abd7bb4e..00000000 --- a/kassette.harformatresponse.headers.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) > [headers](./kassette.harformatresponse.headers.md) - -## HarFormatResponse.headers property - -List of response headers. - -**Signature:** - -```typescript -headers?: HarFormatNameValuePair[]; -``` diff --git a/kassette.harformatresponse.headerssize.md b/kassette.harformatresponse.headerssize.md deleted file mode 100644 index 4b534fd6..00000000 --- a/kassette.harformatresponse.headerssize.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) > [headersSize](./kassette.harformatresponse.headerssize.md) - -## HarFormatResponse.headersSize property - -Total number of bytes from the start of the HTTP response message until (and including) the double CRLF before the body, or -1 if it is unknown. kassette always sets -1 for this field. - -**Signature:** - -```typescript -headersSize?: number; -``` diff --git a/kassette.harformatresponse.httpversion.md b/kassette.harformatresponse.httpversion.md deleted file mode 100644 index 910a365d..00000000 --- a/kassette.harformatresponse.httpversion.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) > [httpVersion](./kassette.harformatresponse.httpversion.md) - -## HarFormatResponse.httpVersion property - -Response HTTP version, such as "HTTP/1.1". - -**Signature:** - -```typescript -httpVersion?: string; -``` diff --git a/kassette.harformatresponse.md b/kassette.harformatresponse.md deleted file mode 100644 index 01c21fae..00000000 --- a/kassette.harformatresponse.md +++ /dev/null @@ -1,29 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) - -## HarFormatResponse interface - -Detailed information about a response, as stored in a har file. - -**Signature:** - -```typescript -export interface HarFormatResponse -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [bodySize?](./kassette.harformatresponse.bodysize.md) | | number | _(Optional)_ Size of the response body in bytes, or -1 if it is unknown. | -| [comment?](./kassette.harformatresponse.comment.md) | | string | _(Optional)_ Any comment as a string. This is not used by kassette. | -| [content?](./kassette.harformatresponse.content.md) | | [HarFormatContent](./kassette.harformatcontent.md) | _(Optional)_ Information about the response body. | -| [cookies?](./kassette.harformatresponse.cookies.md) | | any\[\] | _(Optional)_ Information about cookies. This is not implemented in kassette. | -| [headers?](./kassette.harformatresponse.headers.md) | | [HarFormatNameValuePair](./kassette.harformatnamevaluepair.md)\[\] | _(Optional)_ List of response headers. | -| [headersSize?](./kassette.harformatresponse.headerssize.md) | | number | _(Optional)_ Total number of bytes from the start of the HTTP response message until (and including) the double CRLF before the body, or -1 if it is unknown. kassette always sets -1 for this field. | -| [httpVersion?](./kassette.harformatresponse.httpversion.md) | | string | _(Optional)_ Response HTTP version, such as "HTTP/1.1". | -| [redirectURL?](./kassette.harformatresponse.redirecturl.md) | | string | _(Optional)_ Content of the Location response header if present. | -| [status?](./kassette.harformatresponse.status.md) | | number | _(Optional)_ Response status. | -| [statusText?](./kassette.harformatresponse.statustext.md) | | string | _(Optional)_ Response status text. | - diff --git a/kassette.harformatresponse.redirecturl.md b/kassette.harformatresponse.redirecturl.md deleted file mode 100644 index 009cfe65..00000000 --- a/kassette.harformatresponse.redirecturl.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) > [redirectURL](./kassette.harformatresponse.redirecturl.md) - -## HarFormatResponse.redirectURL property - -Content of the `Location` response header if present. - -**Signature:** - -```typescript -redirectURL?: string; -``` diff --git a/kassette.harformatresponse.status.md b/kassette.harformatresponse.status.md deleted file mode 100644 index ec2e9f91..00000000 --- a/kassette.harformatresponse.status.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) > [status](./kassette.harformatresponse.status.md) - -## HarFormatResponse.status property - -Response status. - -**Signature:** - -```typescript -status?: number; -``` diff --git a/kassette.harformatresponse.statustext.md b/kassette.harformatresponse.statustext.md deleted file mode 100644 index 55f9dc13..00000000 --- a/kassette.harformatresponse.statustext.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatResponse](./kassette.harformatresponse.md) > [statusText](./kassette.harformatresponse.statustext.md) - -## HarFormatResponse.statusText property - -Response status text. - -**Signature:** - -```typescript -statusText?: string; -``` diff --git a/kassette.harformattimings.comment.md b/kassette.harformattimings.comment.md deleted file mode 100644 index 2de15367..00000000 --- a/kassette.harformattimings.comment.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatTimings](./kassette.harformattimings.md) > [comment](./kassette.harformattimings.comment.md) - -## HarFormatTimings.comment property - -Any comment as a string. This is not used by kassette. - -**Signature:** - -```typescript -comment?: string; -``` diff --git a/kassette.harformattimings.md b/kassette.harformattimings.md deleted file mode 100644 index 26bfceb4..00000000 --- a/kassette.harformattimings.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarFormatTimings](./kassette.harformattimings.md) - -## HarFormatTimings interface - -Details about the time spent for each phase of a request-response round trip, as stored in a har file. - -**Signature:** - -```typescript -export interface HarFormatTimings extends RequestTimings -``` -**Extends:** [RequestTimings](./kassette.requesttimings.md) - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [comment?](./kassette.harformattimings.comment.md) | | string | _(Optional)_ Any comment as a string. This is not used by kassette. | - diff --git a/kassette.harkeymanager.md b/kassette.harkeymanager.md deleted file mode 100644 index f19f34a7..00000000 --- a/kassette.harkeymanager.md +++ /dev/null @@ -1,44 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HarKeyManager](./kassette.harkeymanager.md) - -## HarKeyManager type - -Each entry in a har file is supposed to have a corresponding unique key (a string). The har key manager is both a getter and a setter for the key of an entry. - -**Signature:** - -```typescript -export type HarKeyManager = (entry: HarFormatEntry, key?: string) => RecursiveArray; -``` -**References:** [HarFormatEntry](./kassette.harformatentry.md), [RecursiveArray](./kassette.recursivearray.md) - -## Remarks - -The har key manager is a function that is called either to get the key of an entry (when the key parameter is undefined) or to set it (when the key parameter is defined). - -It should not modify the entry when the key parameter is undefined. - -When the key parameter is defined, the har key manager is supposed to change the provided entry, in order to store the key in it, because after the call, the entry will be persisted in the har file. In this case, the key parameter either comes from a call to [IMock.setMockHarKey()](./kassette.imock.setmockharkey.md), or from [defaultMockHarKey](./kassette.imock.defaultmockharkey.md). - -In order to compute the [defaultMockHarKey](./kassette.imock.defaultmockharkey.md) property, the har key manager is called with an entry that includes the request but not the response (and with an undefined key parameter). - -In all cases, the har key manager is expected to return the key of the entry. If an array is returned (which can be nested), it is flattened with null items removed, and joined with forward slashes to produce a string. - -The default har key manager is expected to work fine for most use cases, especially when working with a har file recorded with kassette. With the default har key manager, if a key is set with [IMock.setMockHarKey()](./kassette.imock.setmockharkey.md), it is stored in the [\_kassetteMockKey](./kassette.harformatentry._kassettemockkey.md) field. Otherwise, the default key is the concatenation of the request method and url, with a separating forward slash. It can be useful to replace the default har key manager with a custom one especially when working with har files that are produced by other applications than kassette, if the default key is not convenient. - -## Example - -Here is the default har key manager: - -```ts -export const defaultHarKeyManager: HarKeyManager = (entry: HarFormatEntry, key?: string) => { - const defaultKey = joinPath(entry._kassetteMockKey ?? [entry.request?.method, entry.request?.url]); - if (key && key !== defaultKey) { - entry._kassetteMockKey = key; - return key; - } - return defaultKey; -}; -``` - diff --git a/kassette.headers_2.md b/kassette.headers_2.md deleted file mode 100644 index cbd8b075..00000000 --- a/kassette.headers_2.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Headers\_2](./kassette.headers_2.md) - -## Headers\_2 type - -A map from strings to strings or array of strings - -**Signature:** - -```typescript -export type Headers = IncomingHttpHeaders; -``` diff --git a/kassette.hookapi.console.md b/kassette.hookapi.console.md deleted file mode 100644 index 6c5fc988..00000000 --- a/kassette.hookapi.console.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HookAPI](./kassette.hookapi.md) > [console](./kassette.hookapi.console.md) - -## HookAPI.console property - -The console object as specified in the [configuration](./kassette.configurationspec.console.md), otherwise it is the global console object (usually the one of the platform). - -**Signature:** - -```typescript -console: ConsoleSpec; -``` diff --git a/kassette.hookapi.md b/kassette.hookapi.md deleted file mode 100644 index 27c119a0..00000000 --- a/kassette.hookapi.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HookAPI](./kassette.hookapi.md) - -## HookAPI interface - -Parameter of the [hook](./kassette.configurationspec.hook.md) callback, that is called for every HTTP request that kassette receives. - -**Signature:** - -```typescript -export interface HookAPI -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [console](./kassette.hookapi.console.md) | | [ConsoleSpec](./kassette.consolespec.md) | The console object as specified in the [configuration](./kassette.configurationspec.console.md), otherwise it is the global console object (usually the one of the platform). | -| [mock](./kassette.hookapi.mock.md) | | [IMock](./kassette.imock.md) | Provides the API to specify how to handle the HTTP request. | - diff --git a/kassette.hookapi.mock.md b/kassette.hookapi.mock.md deleted file mode 100644 index ea42962f..00000000 --- a/kassette.hookapi.mock.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [HookAPI](./kassette.hookapi.md) > [mock](./kassette.hookapi.mock.md) - -## HookAPI.mock property - -Provides the API to specify how to handle the HTTP request. - -**Signature:** - -```typescript -mock: IMock; -``` diff --git a/kassette.iconfigurationfile.getconfiguration.md b/kassette.iconfigurationfile.getconfiguration.md deleted file mode 100644 index 96351a38..00000000 --- a/kassette.iconfigurationfile.getconfiguration.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IConfigurationFile](./kassette.iconfigurationfile.md) > [getConfiguration](./kassette.iconfigurationfile.getconfiguration.md) - -## IConfigurationFile.getConfiguration() method - -Function returning the configuration to be used by kassette. - -**Signature:** - -```typescript -getConfiguration(arg: GetConfigurationProps): ConfigurationSpec | Promise; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| arg | [GetConfigurationProps](./kassette.getconfigurationprops.md) | contains information that can be used to build the configuration. | - -**Returns:** - -[ConfigurationSpec](./kassette.configurationspec.md) \| Promise<[ConfigurationSpec](./kassette.configurationspec.md)> - diff --git a/kassette.iconfigurationfile.md b/kassette.iconfigurationfile.md deleted file mode 100644 index e79bf4e3..00000000 --- a/kassette.iconfigurationfile.md +++ /dev/null @@ -1,20 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IConfigurationFile](./kassette.iconfigurationfile.md) - -## IConfigurationFile interface - -Interface that a kassette configuration file should export. - -**Signature:** - -```typescript -export interface IConfigurationFile -``` - -## Methods - -| Method | Description | -| --- | --- | -| [getConfiguration(arg)](./kassette.iconfigurationfile.getconfiguration.md) | Function returning the configuration to be used by kassette. | - diff --git a/kassette.iconfigurationproperty.md b/kassette.iconfigurationproperty.md deleted file mode 100644 index cd19f4aa..00000000 --- a/kassette.iconfigurationproperty.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IConfigurationProperty](./kassette.iconfigurationproperty.md) - -## IConfigurationProperty interface - -Contains the value and origin of a configuration property. - -**Signature:** - -```typescript -export interface IConfigurationProperty -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [origin](./kassette.iconfigurationproperty.origin.md) | readonly | [ConfigurationPropertySource](./kassette.configurationpropertysource.md) | The id of the source of the resolved value of the property | -| [value](./kassette.iconfigurationproperty.value.md) | readonly | PropertyType | The resolved value of the property | - diff --git a/kassette.iconfigurationproperty.origin.md b/kassette.iconfigurationproperty.origin.md deleted file mode 100644 index bb3941fa..00000000 --- a/kassette.iconfigurationproperty.origin.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IConfigurationProperty](./kassette.iconfigurationproperty.md) > [origin](./kassette.iconfigurationproperty.origin.md) - -## IConfigurationProperty.origin property - -The id of the source of the resolved value of the property - -**Signature:** - -```typescript -readonly origin: ConfigurationPropertySource; -``` diff --git a/kassette.iconfigurationproperty.value.md b/kassette.iconfigurationproperty.value.md deleted file mode 100644 index 8e92f763..00000000 --- a/kassette.iconfigurationproperty.value.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IConfigurationProperty](./kassette.iconfigurationproperty.md) > [value](./kassette.iconfigurationproperty.value.md) - -## IConfigurationProperty.value property - -The resolved value of the property - -**Signature:** - -```typescript -readonly value: PropertyType; -``` diff --git a/kassette.ifetchedrequest.body.md b/kassette.ifetchedrequest.body.md deleted file mode 100644 index 3ef903cf..00000000 --- a/kassette.ifetchedrequest.body.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [body](./kassette.ifetchedrequest.body.md) - -## IFetchedRequest.body property - -The body content - -**Signature:** - -```typescript -readonly body: Buffer; -``` diff --git a/kassette.ifetchedrequest.connection.md b/kassette.ifetchedrequest.connection.md deleted file mode 100644 index 43a85ce8..00000000 --- a/kassette.ifetchedrequest.connection.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [connection](./kassette.ifetchedrequest.connection.md) - -## IFetchedRequest.connection property - -The last connection in connectionsStack - -**Signature:** - -```typescript -readonly connection: Readonly; -``` diff --git a/kassette.ifetchedrequest.connectionsstack.md b/kassette.ifetchedrequest.connectionsstack.md deleted file mode 100644 index c4a533ed..00000000 --- a/kassette.ifetchedrequest.connectionsstack.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [connectionsStack](./kassette.ifetchedrequest.connectionsstack.md) - -## IFetchedRequest.connectionsStack property - -The connections stack - -**Signature:** - -```typescript -readonly connectionsStack: readonly Readonly[]; -``` diff --git a/kassette.ifetchedrequest.headers.md b/kassette.ifetchedrequest.headers.md deleted file mode 100644 index 2a3341c7..00000000 --- a/kassette.ifetchedrequest.headers.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [headers](./kassette.ifetchedrequest.headers.md) - -## IFetchedRequest.headers property - -The headers - -**Signature:** - -```typescript -readonly headers: IncomingHttpHeaders; -``` diff --git a/kassette.ifetchedrequest.hostname.md b/kassette.ifetchedrequest.hostname.md deleted file mode 100644 index da95496e..00000000 --- a/kassette.ifetchedrequest.hostname.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [hostname](./kassette.ifetchedrequest.hostname.md) - -## IFetchedRequest.hostname property - -The hostname part of the URL - -**Signature:** - -```typescript -readonly hostname: string; -``` diff --git a/kassette.ifetchedrequest.md b/kassette.ifetchedrequest.md deleted file mode 100644 index 71bc7b9c..00000000 --- a/kassette.ifetchedrequest.md +++ /dev/null @@ -1,31 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) - -## IFetchedRequest interface - -A handier wrapper around a request - -**Signature:** - -```typescript -export interface IFetchedRequest -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [body](./kassette.ifetchedrequest.body.md) | readonly | Buffer | The body content | -| [connection](./kassette.ifetchedrequest.connection.md) | readonly | Readonly<[Connection](./kassette.connection.md)> | The last connection in connectionsStack | -| [connectionsStack](./kassette.ifetchedrequest.connectionsstack.md) | readonly | readonly Readonly<[Connection](./kassette.connection.md)>\[\] | The connections stack | -| [headers](./kassette.ifetchedrequest.headers.md) | readonly | IncomingHttpHeaders | The headers | -| [hostname](./kassette.ifetchedrequest.hostname.md) | readonly | string | The hostname part of the URL | -| [method](./kassette.ifetchedrequest.method.md) | readonly | string | The HTTP method | -| [original](./kassette.ifetchedrequest.original.md) | readonly | IncomingMessage \| Http2ServerRequest | The original Node.js object representing the request | -| [pathname](./kassette.ifetchedrequest.pathname.md) | readonly | string | The path part of the URL | -| [port](./kassette.ifetchedrequest.port.md) | readonly | string | The port part of the URL | -| [protocol](./kassette.ifetchedrequest.protocol.md) | readonly | string | The protocol part of the URL, without the trailing : | -| [queryParameters](./kassette.ifetchedrequest.queryparameters.md) | readonly | Readonly<Record<string, string>> | The query parameters taken from the URL, as a read-only map of strings | -| [url](./kassette.ifetchedrequest.url.md) | readonly | URL | The URL | - diff --git a/kassette.ifetchedrequest.method.md b/kassette.ifetchedrequest.method.md deleted file mode 100644 index 27c9ecfa..00000000 --- a/kassette.ifetchedrequest.method.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [method](./kassette.ifetchedrequest.method.md) - -## IFetchedRequest.method property - -The HTTP method - -**Signature:** - -```typescript -readonly method: string; -``` diff --git a/kassette.ifetchedrequest.original.md b/kassette.ifetchedrequest.original.md deleted file mode 100644 index 216cb4f1..00000000 --- a/kassette.ifetchedrequest.original.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [original](./kassette.ifetchedrequest.original.md) - -## IFetchedRequest.original property - -The original Node.js object representing the request - -**Signature:** - -```typescript -readonly original: IncomingMessage | Http2ServerRequest; -``` diff --git a/kassette.ifetchedrequest.pathname.md b/kassette.ifetchedrequest.pathname.md deleted file mode 100644 index d7019574..00000000 --- a/kassette.ifetchedrequest.pathname.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [pathname](./kassette.ifetchedrequest.pathname.md) - -## IFetchedRequest.pathname property - -The path part of the URL - -**Signature:** - -```typescript -readonly pathname: string; -``` diff --git a/kassette.ifetchedrequest.port.md b/kassette.ifetchedrequest.port.md deleted file mode 100644 index 85c5f7e9..00000000 --- a/kassette.ifetchedrequest.port.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [port](./kassette.ifetchedrequest.port.md) - -## IFetchedRequest.port property - -The port part of the URL - -**Signature:** - -```typescript -readonly port: string; -``` diff --git a/kassette.ifetchedrequest.protocol.md b/kassette.ifetchedrequest.protocol.md deleted file mode 100644 index 0d947961..00000000 --- a/kassette.ifetchedrequest.protocol.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [protocol](./kassette.ifetchedrequest.protocol.md) - -## IFetchedRequest.protocol property - -The protocol part of the URL, without the trailing `:` - -**Signature:** - -```typescript -readonly protocol: string; -``` diff --git a/kassette.ifetchedrequest.queryparameters.md b/kassette.ifetchedrequest.queryparameters.md deleted file mode 100644 index fbd3eb7e..00000000 --- a/kassette.ifetchedrequest.queryparameters.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [queryParameters](./kassette.ifetchedrequest.queryparameters.md) - -## IFetchedRequest.queryParameters property - -The query parameters taken from the URL, as a read-only map of strings - -**Signature:** - -```typescript -readonly queryParameters: Readonly>; -``` diff --git a/kassette.ifetchedrequest.url.md b/kassette.ifetchedrequest.url.md deleted file mode 100644 index bea3bea6..00000000 --- a/kassette.ifetchedrequest.url.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IFetchedRequest](./kassette.ifetchedrequest.md) > [url](./kassette.ifetchedrequest.url.md) - -## IFetchedRequest.url property - -The URL - -**Signature:** - -```typescript -readonly url: URL; -``` diff --git a/kassette.imergedconfiguration.md b/kassette.imergedconfiguration.md deleted file mode 100644 index 99934812..00000000 --- a/kassette.imergedconfiguration.md +++ /dev/null @@ -1,23 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMergedConfiguration](./kassette.imergedconfiguration.md) - -## IMergedConfiguration type - -The resulting configuration that was merged from its different [sources](./kassette.configurationpropertysource.md). - -**Signature:** - -```typescript -export type IMergedConfiguration = { - readonly filePath: string | null; -} & { - readonly [k in keyof ConfigurationSpec]-?: IConfigurationProperty[k]>; -}; -``` -**References:** [ConfigurationSpec](./kassette.configurationspec.md), [IConfigurationProperty](./kassette.iconfigurationproperty.md) - -## Remarks - -It contains the path to the configuration file in `filePath`, and also for each property defined in [ConfigurationSpec](./kassette.configurationspec.md), there is an [IConfigurationProperty](./kassette.iconfigurationproperty.md) object describing the [origin](./kassette.iconfigurationproperty.origin.md) of the property and its [value](./kassette.iconfigurationproperty.value.md). - diff --git a/kassette.imock.checksum.md b/kassette.imock.checksum.md deleted file mode 100644 index 7d09d227..00000000 --- a/kassette.imock.checksum.md +++ /dev/null @@ -1,36 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [checksum](./kassette.imock.checksum.md) - -## IMock.checksum() method - -Compute a checksum using content from the request. - -**Signature:** - -```typescript -checksum(spec: ChecksumArgs): Promise; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| spec | [ChecksumArgs](./kassette.checksumargs.md) | specifies which data from the request to include in the checksum | - -**Returns:** - -Promise<string> - -The actual checksum value, that you can then use for instance to add to the mock's path. - -## Remarks - -The computed checksum is intended to be added to the path of the mock so that semantically different requests use different mocks. - -It is difficult to predict what will actually be relevant to include in the checksum or not for your use case, and that's why we provide many options to include/exclude/transform data (cf [ChecksumArgs](./kassette.checksumargs.md)). - -Note that we designed the API so that it is usually not needed to call the checksum method more than once for a given request/mock. - -The method stores the computed content (which is passed to the hash algorithm) in property [checksumContent](./kassette.imock.checksumcontent.md) (in the `mock` object), as a string. It is built according to your options and the request's data. It is also persisted, so that you can debug more easily, especially by committing it into your SCM to analyze changes across versions of your code. File is along with the other files of the mock under file name `checksum`. - diff --git a/kassette.imock.checksumcontent.md b/kassette.imock.checksumcontent.md deleted file mode 100644 index 616d6e8f..00000000 --- a/kassette.imock.checksumcontent.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [checksumContent](./kassette.imock.checksumcontent.md) - -## IMock.checksumContent property - -Content produced by the last call to the [checksum](./kassette.imock.checksum.md) method, as it was passed to the hash algorithm. - -**Signature:** - -```typescript -readonly checksumContent: string | null; -``` diff --git a/kassette.imock.createpayload.md b/kassette.imock.createpayload.md deleted file mode 100644 index 087da8e5..00000000 --- a/kassette.imock.createpayload.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [createPayload](./kassette.imock.createpayload.md) - -## IMock.createPayload() method - -Create a wrapped payload (with `user` origin) from the given payload data. - -**Signature:** - -```typescript -createPayload(payload: Payload): PayloadWithOrigin<'user'>; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| payload | [Payload](./kassette.payload.md) | payload data | - -**Returns:** - -[PayloadWithOrigin](./kassette.payloadwithorigin.md)<'user'> - diff --git a/kassette.imock.defaultlocalpath.md b/kassette.imock.defaultlocalpath.md deleted file mode 100644 index 8eed708d..00000000 --- a/kassette.imock.defaultlocalpath.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [defaultLocalPath](./kassette.imock.defaultlocalpath.md) - -## IMock.defaultLocalPath property - -Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'folder', specifies the default local path of the mock, relative to [mocksFolder](./kassette.imock.mocksfolder.md), . It uses the URL pathname to build an equivalent folders hierarchy, and appends the HTTP method as a leaf folder. - -**Signature:** - -```typescript -readonly defaultLocalPath: string; -``` diff --git a/kassette.imock.defaultmockharkey.md b/kassette.imock.defaultmockharkey.md deleted file mode 100644 index fa692746..00000000 --- a/kassette.imock.defaultmockharkey.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [defaultMockHarKey](./kassette.imock.defaultmockharkey.md) - -## IMock.defaultMockHarKey property - -Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', specifies the default mock har key to use in case [setMockHarKey](./kassette.imock.setmockharkey.md) is not called with a non-null value. It is computed by calling the [mocks har key manager](./kassette.imock.mocksharkeymanager.md) with the current request. - -**Signature:** - -```typescript -readonly defaultMockHarKey?: string; -``` - -## Remarks - -Note that it is lazily computed, but once computed, it is not re-computed even if [mocksHarKeyManager](./kassette.imock.mocksharkeymanager.md) changes. - diff --git a/kassette.imock.delay.md b/kassette.imock.delay.md deleted file mode 100644 index 156e0f87..00000000 --- a/kassette.imock.delay.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [delay](./kassette.imock.delay.md) - -## IMock.delay property - -The currently computed delay that will be applied, configured either by a call to [setDelay](./kassette.imock.setdelay.md), or by [the global setting](./kassette.cliconfigurationspec.delay.md). Note that if the delay is set to `recorded` and the local mock to use is not yet loaded, the value returned by this getter will be the default delay and not the recorded delay. - -**Signature:** - -```typescript -readonly delay: number; -``` diff --git a/kassette.imock.downloadpayload.md b/kassette.imock.downloadpayload.md deleted file mode 100644 index e7895508..00000000 --- a/kassette.imock.downloadpayload.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [downloadPayload](./kassette.imock.downloadpayload.md) - -## IMock.downloadPayload() method - -Combines [fetchPayload](./kassette.imock.fetchpayload.md) and [persistPayload](./kassette.imock.persistpayload.md) and returns the wrapped payload. - -**Signature:** - -```typescript -downloadPayload(): Promise; -``` -**Returns:** - -Promise<[RemotePayload](./kassette.remotepayload.md)> - diff --git a/kassette.imock.fetchpayload.md b/kassette.imock.fetchpayload.md deleted file mode 100644 index ac2cbd30..00000000 --- a/kassette.imock.fetchpayload.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [fetchPayload](./kassette.imock.fetchpayload.md) - -## IMock.fetchPayload() method - -Forward the client request to the remote backend and get a wrapped payload from the response in output. - -**Signature:** - -```typescript -fetchPayload(): Promise; -``` -**Returns:** - -Promise<[RemotePayload](./kassette.remotepayload.md)> - diff --git a/kassette.imock.fillresponsefrompayload.md b/kassette.imock.fillresponsefrompayload.md deleted file mode 100644 index b4094d97..00000000 --- a/kassette.imock.fillresponsefrompayload.md +++ /dev/null @@ -1,28 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [fillResponseFromPayload](./kassette.imock.fillresponsefrompayload.md) - -## IMock.fillResponseFromPayload() method - -Use data present in given wrapped payload to fill in the response. - -**Signature:** - -```typescript -fillResponseFromPayload(payload: PayloadWithOrigin): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| payload | [PayloadWithOrigin](./kassette.payloadwithorigin.md) | payload to use to fill the response. | - -**Returns:** - -void - -## Remarks - -This method changes [sourcePayload](./kassette.imock.sourcepayload.md). It does nothing if [sourcePayload](./kassette.imock.sourcepayload.md) is already set. - diff --git a/kassette.imock.getpayloadandfillresponse.md b/kassette.imock.getpayloadandfillresponse.md deleted file mode 100644 index e609d980..00000000 --- a/kassette.imock.getpayloadandfillresponse.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [getPayloadAndFillResponse](./kassette.imock.getpayloadandfillresponse.md) - -## IMock.getPayloadAndFillResponse() method - -Depending on the [mode](./kassette.imock.mode.md), gets the payload (remote / local / default) and uses [fillResponseFromPayload](./kassette.imock.fillresponsefrompayload.md) with that payload. If [mode](./kassette.imock.mode.md) is `manual`, does nothing. - -**Signature:** - -```typescript -getPayloadAndFillResponse(): Promise; -``` -**Returns:** - -Promise<void> - diff --git a/kassette.imock.harmimetypesparsejson.md b/kassette.imock.harmimetypesparsejson.md deleted file mode 100644 index 70cff44a..00000000 --- a/kassette.imock.harmimetypesparsejson.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [harMimeTypesParseJson](./kassette.imock.harmimetypesparsejson.md) - -## IMock.harMimeTypesParseJson property - -Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', specifies a list of mime types that will attempt to parse the request/response body as JSON. This will only be applicable to request bodies if [saveInputRequestBody](./kassette.imock.saveinputrequestbody.md) is set to true Default value will be \[\] and will only be overridden by [setHarMimeTypesParseJson](./kassette.imock.setharmimetypesparsejson.md) - -**Signature:** - -```typescript -readonly harMimeTypesParseJson: string[]; -``` diff --git a/kassette.imock.haslocalfiles.md b/kassette.imock.haslocalfiles.md deleted file mode 100644 index 8344a14c..00000000 --- a/kassette.imock.haslocalfiles.md +++ /dev/null @@ -1,26 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [hasLocalFiles](./kassette.imock.haslocalfiles.md) - -## IMock.hasLocalFiles() method - -> Warning: This API is now obsolete. -> -> Use [IMock.hasLocalMock()](./kassette.imock.haslocalmock.md) instead. -> - -Returns true if the mock exists locally. - -**Signature:** - -```typescript -hasLocalFiles(): Promise; -``` -**Returns:** - -Promise<boolean> - -## Remarks - -[hasNoLocalFiles](./kassette.imock.hasnolocalfiles.md) returns the opposite boolean value. - diff --git a/kassette.imock.haslocalmock.md b/kassette.imock.haslocalmock.md deleted file mode 100644 index 2c90f7e9..00000000 --- a/kassette.imock.haslocalmock.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [hasLocalMock](./kassette.imock.haslocalmock.md) - -## IMock.hasLocalMock() method - -Returns true if the mock exists locally. - -**Signature:** - -```typescript -hasLocalMock(): Promise; -``` -**Returns:** - -Promise<boolean> - -## Remarks - -[hasNoLocalMock](./kassette.imock.hasnolocalmock.md) returns the opposite boolean value. - diff --git a/kassette.imock.hasnolocalfiles.md b/kassette.imock.hasnolocalfiles.md deleted file mode 100644 index dec3b9da..00000000 --- a/kassette.imock.hasnolocalfiles.md +++ /dev/null @@ -1,26 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [hasNoLocalFiles](./kassette.imock.hasnolocalfiles.md) - -## IMock.hasNoLocalFiles() method - -> Warning: This API is now obsolete. -> -> Use [IMock.hasNoLocalMock()](./kassette.imock.hasnolocalmock.md) instead. -> - -Returns true if the mock does not exist locally. - -**Signature:** - -```typescript -hasNoLocalFiles(): Promise; -``` -**Returns:** - -Promise<boolean> - -## Remarks - -[hasLocalFiles](./kassette.imock.haslocalfiles.md) returns the opposite boolean value. - diff --git a/kassette.imock.hasnolocalmock.md b/kassette.imock.hasnolocalmock.md deleted file mode 100644 index 4d1b7cae..00000000 --- a/kassette.imock.hasnolocalmock.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [hasNoLocalMock](./kassette.imock.hasnolocalmock.md) - -## IMock.hasNoLocalMock() method - -Returns true if the mock does not exist locally. - -**Signature:** - -```typescript -hasNoLocalMock(): Promise; -``` -**Returns:** - -Promise<boolean> - -## Remarks - -[hasLocalMock](./kassette.imock.haslocalmock.md) returns the opposite boolean value. - diff --git a/kassette.imock.localpath.md b/kassette.imock.localpath.md deleted file mode 100644 index 6133bb8d..00000000 --- a/kassette.imock.localpath.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [localPath](./kassette.imock.localpath.md) - -## IMock.localPath property - -Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'folder', specifies the local path of the mock, relative to [mocksFolder](./kassette.imock.mocksfolder.md). It is either the one set by the user through [setLocalPath](./kassette.imock.setlocalpath.md) or [defaultLocalPath](./kassette.imock.defaultlocalpath.md). - -**Signature:** - -```typescript -readonly localPath: string; -``` diff --git a/kassette.imock.md b/kassette.imock.md deleted file mode 100644 index 6037dda6..00000000 --- a/kassette.imock.md +++ /dev/null @@ -1,84 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) - -## IMock interface - -The public interface exposed to the end user to handle a given request and the associated mock and response. - -An object implementing this interface is passed to the [hook](./kassette.configurationspec.hook.md) function, under property `mock` of the single argument object. - -**Signature:** - -```typescript -export interface IMock -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [checksumContent](./kassette.imock.checksumcontent.md) | readonly | string \| null | Content produced by the last call to the [checksum](./kassette.imock.checksum.md) method, as it was passed to the hash algorithm. | -| [defaultLocalPath](./kassette.imock.defaultlocalpath.md) | readonly | string | Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'folder', specifies the default local path of the mock, relative to [mocksFolder](./kassette.imock.mocksfolder.md), . It uses the URL pathname to build an equivalent folders hierarchy, and appends the HTTP method as a leaf folder. | -| [defaultMockHarKey?](./kassette.imock.defaultmockharkey.md) | readonly | string | _(Optional)_ Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', specifies the default mock har key to use in case [setMockHarKey](./kassette.imock.setmockharkey.md) is not called with a non-null value. It is computed by calling the [mocks har key manager](./kassette.imock.mocksharkeymanager.md) with the current request. | -| [delay](./kassette.imock.delay.md) | readonly | number | The currently computed delay that will be applied, configured either by a call to [setDelay](./kassette.imock.setdelay.md), or by [the global setting](./kassette.cliconfigurationspec.delay.md). Note that if the delay is set to recorded and the local mock to use is not yet loaded, the value returned by this getter will be the default delay and not the recorded delay. | -| [harMimeTypesParseJson](./kassette.imock.harmimetypesparsejson.md) | readonly | string\[\] | Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', specifies a list of mime types that will attempt to parse the request/response body as JSON. This will only be applicable to request bodies if [saveInputRequestBody](./kassette.imock.saveinputrequestbody.md) is set to true Default value will be \[\] and will only be overridden by [setHarMimeTypesParseJson](./kassette.imock.setharmimetypesparsejson.md) | -| [localPath](./kassette.imock.localpath.md) | readonly | string | Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'folder', specifies the local path of the mock, relative to [mocksFolder](./kassette.imock.mocksfolder.md). It is either the one set by the user through [setLocalPath](./kassette.imock.setlocalpath.md) or [defaultLocalPath](./kassette.imock.defaultlocalpath.md). | -| [mockFolderFullPath](./kassette.imock.mockfolderfullpath.md) | readonly | string | Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'folder', specifies the full, absolute path of the mock, built from [localPath](./kassette.imock.localpath.md)/[defaultLocalPath](./kassette.imock.defaultlocalpath.md), [mocksFolder](./kassette.imock.mocksfolder.md) and possibly [options.root](./kassette.mockingoptions.root.md) if [mocksFolder](./kassette.imock.mocksfolder.md) is not absolute. | -| [mockHarKey?](./kassette.imock.mockharkey.md) | readonly | string | _(Optional)_ Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', specifies the key to use inside the har file to either read or write a mock. | -| [mocksFolder](./kassette.imock.mocksfolder.md) | readonly | string | Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'folder', specifies the root folder of all mocks, from which specific mocks paths will be resolved (resolved against [options.root](./kassette.mockingoptions.root.md)). | -| [mocksFormat](./kassette.imock.mocksformat.md) | readonly | [MocksFormat](./kassette.mocksformat.md) | The mocks format used for this request. | -| [mocksHarFile](./kassette.imock.mocksharfile.md) | readonly | string | Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', contains the full path of the the har file to use. If the file name has the .yml or .yaml extension, the YAML format is used instead of the standard JSON format to read and write the file. | -| [mocksHarKeyManager](./kassette.imock.mocksharkeymanager.md) | readonly | [HarKeyManager](./kassette.harkeymanager.md) | Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', specifies the [har key manager](./kassette.harkeymanager.md) to use. | -| [mode](./kassette.imock.mode.md) | readonly | [Mode](./kassette.mode.md) | The current mode, configured either by a call to [setMode](./kassette.imock.setmode.md), or by [the global setting](./kassette.cliconfigurationspec.mode.md). | -| [options](./kassette.imock.options.md) | readonly | [MockingOptions](./kassette.mockingoptions.md) | Link to global configuration options | -| [remoteURL](./kassette.imock.remoteurl.md) | readonly | string \| null | The current remote URL, configured either by a call to [setRemoteURL](./kassette.imock.setremoteurl.md), or by [the global setting](./kassette.cliconfigurationspec.remoteurl.md). | -| [request](./kassette.imock.request.md) | readonly | [IFetchedRequest](./kassette.ifetchedrequest.md) | The wrapper around the input request | -| [response](./kassette.imock.response.md) | readonly | [IResponse](./kassette.iresponse.md) | The wrapper around the output response | -| [saveChecksumContent](./kassette.imock.savechecksumcontent.md) | readonly | boolean | Whether to save the content used to create a checksum when creating a new mock with a checksum for this request. | -| [saveDetailedTimings](./kassette.imock.savedetailedtimings.md) | readonly | boolean | Whether to save [detailed timings](./kassette.requesttimings.md) when creating a new mock for this request. | -| [saveForwardedRequestBody](./kassette.imock.saveforwardedrequestbody.md) | readonly | boolean | Whether to save the forwarded request body when creating a new mock for this request. | -| [saveForwardedRequestData](./kassette.imock.saveforwardedrequestdata.md) | readonly | boolean | Whether to save the forwarded request data (headers, method, URL) when creating a new mock for this request. | -| [saveInputRequestBody](./kassette.imock.saveinputrequestbody.md) | readonly | boolean | Whether to save the content of the input request body when creating a new mock for this request. | -| [saveInputRequestData](./kassette.imock.saveinputrequestdata.md) | readonly | boolean | Whether to save the input request data (headers, method, URL) when creating a new mock for this request. | -| [sourcePayload](./kassette.imock.sourcepayload.md) | | [PayloadWithOrigin](./kassette.payloadwithorigin.md) \| undefined | As soon as response is filled with a payload, this property holds the reference to that payload's wrapper. The wrapper is useful here to know where the payload comes from. Before that, this property is undefined. | - -## Methods - -| Method | Description | -| --- | --- | -| [checksum(spec)](./kassette.imock.checksum.md) | Compute a checksum using content from the request. | -| [createPayload(payload)](./kassette.imock.createpayload.md) | Create a wrapped payload (with user origin) from the given payload data. | -| [downloadPayload()](./kassette.imock.downloadpayload.md) | Combines [fetchPayload](./kassette.imock.fetchpayload.md) and [persistPayload](./kassette.imock.persistpayload.md) and returns the wrapped payload. | -| [fetchPayload()](./kassette.imock.fetchpayload.md) | Forward the client request to the remote backend and get a wrapped payload from the response in output. | -| [fillResponseFromPayload(payload)](./kassette.imock.fillresponsefrompayload.md) | Use data present in given wrapped payload to fill in the response. | -| [getPayloadAndFillResponse()](./kassette.imock.getpayloadandfillresponse.md) | Depending on the [mode](./kassette.imock.mode.md), gets the payload (remote / local / default) and uses [fillResponseFromPayload](./kassette.imock.fillresponsefrompayload.md) with that payload. If [mode](./kassette.imock.mode.md) is manual, does nothing. | -| [hasLocalFiles()](./kassette.imock.haslocalfiles.md) | Returns true if the mock exists locally. | -| [hasLocalMock()](./kassette.imock.haslocalmock.md) | Returns true if the mock exists locally. | -| [hasNoLocalFiles()](./kassette.imock.hasnolocalfiles.md) | Returns true if the mock does not exist locally. | -| [hasNoLocalMock()](./kassette.imock.hasnolocalmock.md) | Returns true if the mock does not exist locally. | -| [persistPayload(payload)](./kassette.imock.persistpayload.md) | Take the given wrapped payload and persist it in local files. | -| [process()](./kassette.imock.process.md) | Combines [getPayloadAndFillResponse](./kassette.imock.getpayloadandfillresponse.md) and [sendResponse](./kassette.imock.sendresponse.md). | -| [readLocalPayload()](./kassette.imock.readlocalpayload.md) | Returns a wrapped payload built from data persisted in local files. If no local file is present, returns undefined. | -| [readLocalPayloadAndFillResponse()](./kassette.imock.readlocalpayloadandfillresponse.md) | Combines [readLocalPayload](./kassette.imock.readlocalpayload.md) and [fillResponseFromPayload](./kassette.imock.fillresponsefrompayload.md) if there is a local payload then returns true, otherwise does nothing and return false. | -| [readOrDownloadPayload()](./kassette.imock.readordownloadpayload.md) | Returns the wrapped local payload using [readLocalPayload](./kassette.imock.readlocalpayload.md) if it exists, otherwise use [downloadPayload](./kassette.imock.downloadpayload.md) and returns this wrapped payload. | -| [readOrFetchPayload()](./kassette.imock.readorfetchpayload.md) | Returns the wrapped local payload using [readLocalPayload](./kassette.imock.readlocalpayload.md) if it exists, otherwise use [fetchPayload](./kassette.imock.fetchpayload.md) and returns this wrapped payload. | -| [sendResponse()](./kassette.imock.sendresponse.md) | Sends the response back to the client, with the previously specified delay if the payload origin is not remote. | -| [setDelay(delay)](./kassette.imock.setdelay.md) | Sets the [delay](./kassette.imock.delay.md) that will be used to send the response to the client when the data is taken from the local mock. | -| [setHarMimeTypesParseJson(value)](./kassette.imock.setharmimetypesparsejson.md) | Sets the [harMimeTypesParseJson](./kassette.imock.harmimetypesparsejson.md) value. | -| [setLocalPath(pathParts)](./kassette.imock.setlocalpath.md) | Sets the [localPath](./kassette.imock.localpath.md) value. | -| [setMockHarKey(value)](./kassette.imock.setmockharkey.md) | Sets the [mockHarKey](./kassette.imock.mockharkey.md) value. | -| [setMocksFolder(value)](./kassette.imock.setmocksfolder.md) | Sets the [mocksFolder](./kassette.imock.mocksfolder.md) value. | -| [setMocksFormat(value)](./kassette.imock.setmocksformat.md) | Sets the [mocksFormat](./kassette.imock.mocksformat.md) value. | -| [setMocksHarFile(value)](./kassette.imock.setmocksharfile.md) | Sets the [mocksHarFile](./kassette.imock.mocksharfile.md) value. | -| [setMocksHarKeyManager(value)](./kassette.imock.setmocksharkeymanager.md) | Sets the [mocksHarKeyManager](./kassette.imock.mocksharkeymanager.md) value. | -| [setMode(mode)](./kassette.imock.setmode.md) | Sets the [mode](./kassette.imock.mode.md) for the current request. | -| [setPayload(payload)](./kassette.imock.setpayload.md) | Sets the current local payload, with a custom one you would have created. | -| [setRemoteURL(url)](./kassette.imock.setremoteurl.md) | Sets the [remote URL](./kassette.imock.remoteurl.md) for the current request. | -| [setSaveChecksumContent(value)](./kassette.imock.setsavechecksumcontent.md) | Sets the [saveChecksumContent](./kassette.imock.savechecksumcontent.md) value. | -| [setSaveDetailedTimings(value)](./kassette.imock.setsavedetailedtimings.md) | Sets the [saveDetailedTimings](./kassette.imock.savedetailedtimings.md) value. | -| [setSaveForwardedRequestBody(value)](./kassette.imock.setsaveforwardedrequestbody.md) | Sets the [saveForwardedRequestBody](./kassette.imock.saveforwardedrequestbody.md) value. | -| [setSaveForwardedRequestData(value)](./kassette.imock.setsaveforwardedrequestdata.md) | Sets the [saveForwardedRequestData](./kassette.imock.saveforwardedrequestdata.md) value. | -| [setSaveInputRequestBody(value)](./kassette.imock.setsaveinputrequestbody.md) | Sets the [saveInputRequestBody](./kassette.imock.saveinputrequestbody.md) value. | -| [setSaveInputRequestData(value)](./kassette.imock.setsaveinputrequestdata.md) | Sets the [saveInputRequestData](./kassette.imock.saveinputrequestdata.md) value. | - diff --git a/kassette.imock.mockfolderfullpath.md b/kassette.imock.mockfolderfullpath.md deleted file mode 100644 index fb0c97d9..00000000 --- a/kassette.imock.mockfolderfullpath.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [mockFolderFullPath](./kassette.imock.mockfolderfullpath.md) - -## IMock.mockFolderFullPath property - -Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'folder', specifies the full, absolute path of the mock, built from [localPath](./kassette.imock.localpath.md)/[defaultLocalPath](./kassette.imock.defaultlocalpath.md), [mocksFolder](./kassette.imock.mocksfolder.md) and possibly [options.root](./kassette.mockingoptions.root.md) if [mocksFolder](./kassette.imock.mocksfolder.md) is not absolute. - -**Signature:** - -```typescript -readonly mockFolderFullPath: string; -``` diff --git a/kassette.imock.mockharkey.md b/kassette.imock.mockharkey.md deleted file mode 100644 index 9c268715..00000000 --- a/kassette.imock.mockharkey.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [mockHarKey](./kassette.imock.mockharkey.md) - -## IMock.mockHarKey property - -Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', specifies the key to use inside the har file to either read or write a mock. - -**Signature:** - -```typescript -readonly mockHarKey?: string; -``` - -## Remarks - -The way the key is stored inside the har file depends on the value of [mocksHarKeyManager](./kassette.imock.mocksharkeymanager.md). - diff --git a/kassette.imock.mocksfolder.md b/kassette.imock.mocksfolder.md deleted file mode 100644 index db7cc6cc..00000000 --- a/kassette.imock.mocksfolder.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [mocksFolder](./kassette.imock.mocksfolder.md) - -## IMock.mocksFolder property - -Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'folder', specifies the root folder of all mocks, from which specific mocks paths will be resolved (resolved against [options.root](./kassette.mockingoptions.root.md)). - -**Signature:** - -```typescript -readonly mocksFolder: string; -``` diff --git a/kassette.imock.mocksformat.md b/kassette.imock.mocksformat.md deleted file mode 100644 index d892d5bc..00000000 --- a/kassette.imock.mocksformat.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [mocksFormat](./kassette.imock.mocksformat.md) - -## IMock.mocksFormat property - -The mocks format used for this request. - -**Signature:** - -```typescript -readonly mocksFormat: MocksFormat; -``` diff --git a/kassette.imock.mocksharfile.md b/kassette.imock.mocksharfile.md deleted file mode 100644 index 25d727c2..00000000 --- a/kassette.imock.mocksharfile.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [mocksHarFile](./kassette.imock.mocksharfile.md) - -## IMock.mocksHarFile property - -Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', contains the full path of the the har file to use. If the file name has the `.yml` or `.yaml` extension, the YAML format is used instead of the standard JSON format to read and write the file. - -**Signature:** - -```typescript -readonly mocksHarFile: string; -``` diff --git a/kassette.imock.mocksharkeymanager.md b/kassette.imock.mocksharkeymanager.md deleted file mode 100644 index 6be13413..00000000 --- a/kassette.imock.mocksharkeymanager.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [mocksHarKeyManager](./kassette.imock.mocksharkeymanager.md) - -## IMock.mocksHarKeyManager property - -Used only when the [mocks format](./kassette.imock.mocksformat.md) is 'har', specifies the [har key manager](./kassette.harkeymanager.md) to use. - -**Signature:** - -```typescript -readonly mocksHarKeyManager: HarKeyManager; -``` diff --git a/kassette.imock.mode.md b/kassette.imock.mode.md deleted file mode 100644 index f04b545f..00000000 --- a/kassette.imock.mode.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [mode](./kassette.imock.mode.md) - -## IMock.mode property - -The current mode, configured either by a call to [setMode](./kassette.imock.setmode.md), or by [the global setting](./kassette.cliconfigurationspec.mode.md). - -**Signature:** - -```typescript -readonly mode: Mode; -``` diff --git a/kassette.imock.options.md b/kassette.imock.options.md deleted file mode 100644 index b8eff35e..00000000 --- a/kassette.imock.options.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [options](./kassette.imock.options.md) - -## IMock.options property - -Link to global configuration options - -**Signature:** - -```typescript -readonly options: MockingOptions; -``` diff --git a/kassette.imock.persistpayload.md b/kassette.imock.persistpayload.md deleted file mode 100644 index 1f91d5fb..00000000 --- a/kassette.imock.persistpayload.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [persistPayload](./kassette.imock.persistpayload.md) - -## IMock.persistPayload() method - -Take the given wrapped payload and persist it in local files. - -**Signature:** - -```typescript -persistPayload(payload: PayloadWithOrigin): Promise; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| payload | [PayloadWithOrigin](./kassette.payloadwithorigin.md) | payload to persist in local files | - -**Returns:** - -Promise<void> - diff --git a/kassette.imock.process.md b/kassette.imock.process.md deleted file mode 100644 index cc12b209..00000000 --- a/kassette.imock.process.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [process](./kassette.imock.process.md) - -## IMock.process() method - -Combines [getPayloadAndFillResponse](./kassette.imock.getpayloadandfillresponse.md) and [sendResponse](./kassette.imock.sendresponse.md). - -**Signature:** - -```typescript -process(): Promise; -``` -**Returns:** - -Promise<void> - -## Remarks - -If [mode](./kassette.imock.mode.md) is `manual`, this method does nothing. It also uses a private guard to make sure it is executed only once. Therefore, if you call it from the [hook](./kassette.configurationspec.hook.md) method, the automatic call made for you after the hook execution will actually not do anything (and the same if you call it yourself multiple times). - diff --git a/kassette.imock.readlocalpayload.md b/kassette.imock.readlocalpayload.md deleted file mode 100644 index 05ca2d08..00000000 --- a/kassette.imock.readlocalpayload.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [readLocalPayload](./kassette.imock.readlocalpayload.md) - -## IMock.readLocalPayload() method - -Returns a wrapped payload built from data persisted in local files. If no local file is present, returns `undefined`. - -**Signature:** - -```typescript -readLocalPayload(): Promise | undefined>; -``` -**Returns:** - -Promise<[PayloadWithOrigin](./kassette.payloadwithorigin.md)<'local' \| 'user'> \| undefined> - diff --git a/kassette.imock.readlocalpayloadandfillresponse.md b/kassette.imock.readlocalpayloadandfillresponse.md deleted file mode 100644 index ff6ee8fe..00000000 --- a/kassette.imock.readlocalpayloadandfillresponse.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [readLocalPayloadAndFillResponse](./kassette.imock.readlocalpayloadandfillresponse.md) - -## IMock.readLocalPayloadAndFillResponse() method - -Combines [readLocalPayload](./kassette.imock.readlocalpayload.md) and [fillResponseFromPayload](./kassette.imock.fillresponsefrompayload.md) if there is a local payload then returns `true`, otherwise does nothing and return `false`. - -**Signature:** - -```typescript -readLocalPayloadAndFillResponse(): Promise; -``` -**Returns:** - -Promise<boolean> - diff --git a/kassette.imock.readordownloadpayload.md b/kassette.imock.readordownloadpayload.md deleted file mode 100644 index dc98e8d5..00000000 --- a/kassette.imock.readordownloadpayload.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [readOrDownloadPayload](./kassette.imock.readordownloadpayload.md) - -## IMock.readOrDownloadPayload() method - -Returns the wrapped local payload using [readLocalPayload](./kassette.imock.readlocalpayload.md) if it exists, otherwise use [downloadPayload](./kassette.imock.downloadpayload.md) and returns this wrapped payload. - -**Signature:** - -```typescript -readOrDownloadPayload(): Promise | RemotePayload>; -``` -**Returns:** - -Promise<[PayloadWithOrigin](./kassette.payloadwithorigin.md)<'local' \| 'user'> \| [RemotePayload](./kassette.remotepayload.md)> - diff --git a/kassette.imock.readorfetchpayload.md b/kassette.imock.readorfetchpayload.md deleted file mode 100644 index 15a32b25..00000000 --- a/kassette.imock.readorfetchpayload.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [readOrFetchPayload](./kassette.imock.readorfetchpayload.md) - -## IMock.readOrFetchPayload() method - -Returns the wrapped local payload using [readLocalPayload](./kassette.imock.readlocalpayload.md) if it exists, otherwise use [fetchPayload](./kassette.imock.fetchpayload.md) and returns this wrapped payload. - -**Signature:** - -```typescript -readOrFetchPayload(): Promise | RemotePayload>; -``` -**Returns:** - -Promise<[PayloadWithOrigin](./kassette.payloadwithorigin.md)<'local' \| 'user'> \| [RemotePayload](./kassette.remotepayload.md)> - diff --git a/kassette.imock.remoteurl.md b/kassette.imock.remoteurl.md deleted file mode 100644 index 09497437..00000000 --- a/kassette.imock.remoteurl.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [remoteURL](./kassette.imock.remoteurl.md) - -## IMock.remoteURL property - -The current remote URL, configured either by a call to [setRemoteURL](./kassette.imock.setremoteurl.md), or by [the global setting](./kassette.cliconfigurationspec.remoteurl.md). - -**Signature:** - -```typescript -readonly remoteURL: string | null; -``` diff --git a/kassette.imock.request.md b/kassette.imock.request.md deleted file mode 100644 index 0ad99900..00000000 --- a/kassette.imock.request.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [request](./kassette.imock.request.md) - -## IMock.request property - -The wrapper around the input request - -**Signature:** - -```typescript -readonly request: IFetchedRequest; -``` diff --git a/kassette.imock.response.md b/kassette.imock.response.md deleted file mode 100644 index d0e9db39..00000000 --- a/kassette.imock.response.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [response](./kassette.imock.response.md) - -## IMock.response property - -The wrapper around the output response - -**Signature:** - -```typescript -readonly response: IResponse; -``` diff --git a/kassette.imock.savechecksumcontent.md b/kassette.imock.savechecksumcontent.md deleted file mode 100644 index 847b077a..00000000 --- a/kassette.imock.savechecksumcontent.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [saveChecksumContent](./kassette.imock.savechecksumcontent.md) - -## IMock.saveChecksumContent property - -Whether to save the content used to create a checksum when creating a new mock with a checksum for this request. - -**Signature:** - -```typescript -readonly saveChecksumContent: boolean; -``` diff --git a/kassette.imock.savedetailedtimings.md b/kassette.imock.savedetailedtimings.md deleted file mode 100644 index ca99767b..00000000 --- a/kassette.imock.savedetailedtimings.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [saveDetailedTimings](./kassette.imock.savedetailedtimings.md) - -## IMock.saveDetailedTimings property - -Whether to save [detailed timings](./kassette.requesttimings.md) when creating a new mock for this request. - -**Signature:** - -```typescript -readonly saveDetailedTimings: boolean; -``` diff --git a/kassette.imock.saveforwardedrequestbody.md b/kassette.imock.saveforwardedrequestbody.md deleted file mode 100644 index b41039cb..00000000 --- a/kassette.imock.saveforwardedrequestbody.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [saveForwardedRequestBody](./kassette.imock.saveforwardedrequestbody.md) - -## IMock.saveForwardedRequestBody property - -Whether to save the forwarded request body when creating a new mock for this request. - -**Signature:** - -```typescript -readonly saveForwardedRequestBody: boolean; -``` diff --git a/kassette.imock.saveforwardedrequestdata.md b/kassette.imock.saveforwardedrequestdata.md deleted file mode 100644 index 4923b538..00000000 --- a/kassette.imock.saveforwardedrequestdata.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [saveForwardedRequestData](./kassette.imock.saveforwardedrequestdata.md) - -## IMock.saveForwardedRequestData property - -Whether to save the forwarded request data (headers, method, URL) when creating a new mock for this request. - -**Signature:** - -```typescript -readonly saveForwardedRequestData: boolean; -``` diff --git a/kassette.imock.saveinputrequestbody.md b/kassette.imock.saveinputrequestbody.md deleted file mode 100644 index eb4bfcb0..00000000 --- a/kassette.imock.saveinputrequestbody.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [saveInputRequestBody](./kassette.imock.saveinputrequestbody.md) - -## IMock.saveInputRequestBody property - -Whether to save the content of the input request body when creating a new mock for this request. - -**Signature:** - -```typescript -readonly saveInputRequestBody: boolean; -``` diff --git a/kassette.imock.saveinputrequestdata.md b/kassette.imock.saveinputrequestdata.md deleted file mode 100644 index f22bb412..00000000 --- a/kassette.imock.saveinputrequestdata.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [saveInputRequestData](./kassette.imock.saveinputrequestdata.md) - -## IMock.saveInputRequestData property - -Whether to save the input request data (headers, method, URL) when creating a new mock for this request. - -**Signature:** - -```typescript -readonly saveInputRequestData: boolean; -``` diff --git a/kassette.imock.sendresponse.md b/kassette.imock.sendresponse.md deleted file mode 100644 index 50ab268f..00000000 --- a/kassette.imock.sendresponse.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [sendResponse](./kassette.imock.sendresponse.md) - -## IMock.sendResponse() method - -Sends the response back to the client, with the previously specified delay if the payload origin is not `remote`. - -**Signature:** - -```typescript -sendResponse(): Promise; -``` -**Returns:** - -Promise<void> - diff --git a/kassette.imock.setdelay.md b/kassette.imock.setdelay.md deleted file mode 100644 index a48e50e7..00000000 --- a/kassette.imock.setdelay.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setDelay](./kassette.imock.setdelay.md) - -## IMock.setDelay() method - -Sets the [delay](./kassette.imock.delay.md) that will be used to send the response to the client when the data is taken from the local mock. - -**Signature:** - -```typescript -setDelay(delay: Delay | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| delay | [Delay](./kassette.delay.md) \| null | can be either a number (to directly specify the delay in milliseconds), 'recorded' (to read the delay from the [time](./kassette.mockdata.time.md) property of an already recorded mock if any) or null (to remove the effect of any previous call of setDelay and use the default value from [the global setting](./kassette.cliconfigurationspec.delay.md) instead). | - -**Returns:** - -void - diff --git a/kassette.imock.setharmimetypesparsejson.md b/kassette.imock.setharmimetypesparsejson.md deleted file mode 100644 index 94095357..00000000 --- a/kassette.imock.setharmimetypesparsejson.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setHarMimeTypesParseJson](./kassette.imock.setharmimetypesparsejson.md) - -## IMock.setHarMimeTypesParseJson() method - -Sets the [harMimeTypesParseJson](./kassette.imock.harmimetypesparsejson.md) value. - -**Signature:** - -```typescript -setHarMimeTypesParseJson(value: string[]): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | string\[\] | The mime types that should attempt to parse the body as json | - -**Returns:** - -void - diff --git a/kassette.imock.setlocalpath.md b/kassette.imock.setlocalpath.md deleted file mode 100644 index 99eda565..00000000 --- a/kassette.imock.setlocalpath.md +++ /dev/null @@ -1,40 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setLocalPath](./kassette.imock.setlocalpath.md) - -## IMock.setLocalPath() method - -Sets the [localPath](./kassette.imock.localpath.md) value. - -**Signature:** - -```typescript -setLocalPath(pathParts: RecursiveArray): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| pathParts | [RecursiveArray](./kassette.recursivearray.md)<string \| null \| undefined> | Any combination of values and array of values, which will eventually all be flattened, converted to strings and joined to build a path. | - -**Returns:** - -void - -## Example 1 - -The following example will use the HTTP method followed by the URL pathname: - -``` -mock.setLocalPath([mock.request.method, mock.request.pathname]) -``` - -## Example 2 - -The following example will concatenate `prefix`, all portions of the URL pathname except the first one (also excluding the very first one which is empty since [IFetchedRequest.pathname](./kassette.ifetchedrequest.pathname.md) has a leading slash) and optionally a suffix sequence depending on a boolean. - -``` -mock.setLocalPath([prefix, mock.request.pathname.split('/').slice(2), addSuffix ? [suffix, '-static-suffix'] : null]) -``` - diff --git a/kassette.imock.setmockharkey.md b/kassette.imock.setmockharkey.md deleted file mode 100644 index 7bb3da48..00000000 --- a/kassette.imock.setmockharkey.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setMockHarKey](./kassette.imock.setmockharkey.md) - -## IMock.setMockHarKey() method - -Sets the [mockHarKey](./kassette.imock.mockharkey.md) value. - -**Signature:** - -```typescript -setMockHarKey(value: RecursiveArray | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | [RecursiveArray](./kassette.recursivearray.md)<string \| null \| undefined> \| null | specifies the key to use inside the har file to either read or write a mock. If an array is set (which can be nested), it is flattened with null items removed, and joined with forward slashes to produce a string. Passing null resets the value to [the default value](./kassette.imock.defaultmockharkey.md). | - -**Returns:** - -void - diff --git a/kassette.imock.setmocksfolder.md b/kassette.imock.setmocksfolder.md deleted file mode 100644 index 2b08d33a..00000000 --- a/kassette.imock.setmocksfolder.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setMocksFolder](./kassette.imock.setmocksfolder.md) - -## IMock.setMocksFolder() method - -Sets the [mocksFolder](./kassette.imock.mocksfolder.md) value. - -**Signature:** - -```typescript -setMocksFolder(value: RecursiveArray | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | [RecursiveArray](./kassette.recursivearray.md)<string \| null \| undefined> \| null | any combination of arrays of path parts, (as it is also possible for [setLocalPath](./kassette.imock.setlocalpath.md)). You can pass an absolute path, or a relative one which will be resolved against [options.root](./kassette.mockingoptions.root.md). Passing null resets the value to the default coming from [the global setting](./kassette.cliconfigurationspec.mocksfolder.md). | - -**Returns:** - -void - diff --git a/kassette.imock.setmocksformat.md b/kassette.imock.setmocksformat.md deleted file mode 100644 index 95917519..00000000 --- a/kassette.imock.setmocksformat.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setMocksFormat](./kassette.imock.setmocksformat.md) - -## IMock.setMocksFormat() method - -Sets the [mocksFormat](./kassette.imock.mocksformat.md) value. - -**Signature:** - -```typescript -setMocksFormat(value: MocksFormat | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | [MocksFormat](./kassette.mocksformat.md) \| null | the mocks format to use for this request. Passing null resets the value to the default coming from [the global setting](./kassette.cliconfigurationspec.mocksformat.md). | - -**Returns:** - -void - diff --git a/kassette.imock.setmocksharfile.md b/kassette.imock.setmocksharfile.md deleted file mode 100644 index 09346cfd..00000000 --- a/kassette.imock.setmocksharfile.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setMocksHarFile](./kassette.imock.setmocksharfile.md) - -## IMock.setMocksHarFile() method - -Sets the [mocksHarFile](./kassette.imock.mocksharfile.md) value. - -**Signature:** - -```typescript -setMocksHarFile(value: RecursiveArray | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | [RecursiveArray](./kassette.recursivearray.md)<string \| null \| undefined> \| null | any combination of arrays of path parts. You can pass an absolute path, or a relative one which will be resolved against [options.root](./kassette.mockingoptions.root.md). Passing null resets the value to the default coming from [the global setting](./kassette.cliconfigurationspec.mocksharfile.md). | - -**Returns:** - -void - diff --git a/kassette.imock.setmocksharkeymanager.md b/kassette.imock.setmocksharkeymanager.md deleted file mode 100644 index 44f675ec..00000000 --- a/kassette.imock.setmocksharkeymanager.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setMocksHarKeyManager](./kassette.imock.setmocksharkeymanager.md) - -## IMock.setMocksHarKeyManager() method - -Sets the [mocksHarKeyManager](./kassette.imock.mocksharkeymanager.md) value. - -**Signature:** - -```typescript -setMocksHarKeyManager(value: HarKeyManager | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | [HarKeyManager](./kassette.harkeymanager.md) \| null | the [har key manager](./kassette.harkeymanager.md) to use for this request. Passing null resets the value to the default coming from [the global setting](./kassette.configurationspec.mocksharkeymanager.md). | - -**Returns:** - -void - diff --git a/kassette.imock.setmode.md b/kassette.imock.setmode.md deleted file mode 100644 index 039b73d0..00000000 --- a/kassette.imock.setmode.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setMode](./kassette.imock.setmode.md) - -## IMock.setMode() method - -Sets the [mode](./kassette.imock.mode.md) for the current request. - -**Signature:** - -```typescript -setMode(mode: Mode | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| mode | [Mode](./kassette.mode.md) \| null | mode to set, or null to use the default value from [the global setting](./kassette.cliconfigurationspec.mode.md) | - -**Returns:** - -void - diff --git a/kassette.imock.setpayload.md b/kassette.imock.setpayload.md deleted file mode 100644 index 4b431bc8..00000000 --- a/kassette.imock.setpayload.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setPayload](./kassette.imock.setpayload.md) - -## IMock.setPayload() method - -Sets the current local payload, with a custom one you would have created. - -**Signature:** - -```typescript -setPayload(payload: PayloadWithOrigin<'local' | 'user'>): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| payload | [PayloadWithOrigin](./kassette.payloadwithorigin.md)<'local' \| 'user'> | payload to set | - -**Returns:** - -void - diff --git a/kassette.imock.setremoteurl.md b/kassette.imock.setremoteurl.md deleted file mode 100644 index ddda31fc..00000000 --- a/kassette.imock.setremoteurl.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setRemoteURL](./kassette.imock.setremoteurl.md) - -## IMock.setRemoteURL() method - -Sets the [remote URL](./kassette.imock.remoteurl.md) for the current request. - -**Signature:** - -```typescript -setRemoteURL(url: string | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| url | string \| null | the URL to set, or null to use the default value from [the global setting](./kassette.cliconfigurationspec.remoteurl.md) | - -**Returns:** - -void - diff --git a/kassette.imock.setsavechecksumcontent.md b/kassette.imock.setsavechecksumcontent.md deleted file mode 100644 index 9dbe985b..00000000 --- a/kassette.imock.setsavechecksumcontent.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setSaveChecksumContent](./kassette.imock.setsavechecksumcontent.md) - -## IMock.setSaveChecksumContent() method - -Sets the [saveChecksumContent](./kassette.imock.savechecksumcontent.md) value. - -**Signature:** - -```typescript -setSaveChecksumContent(value: boolean | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | boolean \| null | whether to save the content used to create a checksum when creating a new mock with a checksum for this request. Passing null resets the value to the default coming from [the global setting](./kassette.cliconfigurationspec.savechecksumcontent.md). | - -**Returns:** - -void - diff --git a/kassette.imock.setsavedetailedtimings.md b/kassette.imock.setsavedetailedtimings.md deleted file mode 100644 index 6cba213a..00000000 --- a/kassette.imock.setsavedetailedtimings.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setSaveDetailedTimings](./kassette.imock.setsavedetailedtimings.md) - -## IMock.setSaveDetailedTimings() method - -Sets the [saveDetailedTimings](./kassette.imock.savedetailedtimings.md) value. - -**Signature:** - -```typescript -setSaveDetailedTimings(value: boolean | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | boolean \| null | whether to save [detailed timings](./kassette.requesttimings.md) when creating a new mock with a checksum for this request. Passing null resets the value to the default coming from [the global setting](./kassette.cliconfigurationspec.savedetailedtimings.md). | - -**Returns:** - -void - diff --git a/kassette.imock.setsaveforwardedrequestbody.md b/kassette.imock.setsaveforwardedrequestbody.md deleted file mode 100644 index 5659bf65..00000000 --- a/kassette.imock.setsaveforwardedrequestbody.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setSaveForwardedRequestBody](./kassette.imock.setsaveforwardedrequestbody.md) - -## IMock.setSaveForwardedRequestBody() method - -Sets the [saveForwardedRequestBody](./kassette.imock.saveforwardedrequestbody.md) value. - -**Signature:** - -```typescript -setSaveForwardedRequestBody(value: boolean | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | boolean \| null | whether to save the forwarded request body when creating a new mock for this request. Passing null resets the value to the default coming from [the global setting](./kassette.cliconfigurationspec.saveforwardedrequestbody.md). | - -**Returns:** - -void - diff --git a/kassette.imock.setsaveforwardedrequestdata.md b/kassette.imock.setsaveforwardedrequestdata.md deleted file mode 100644 index 77701d61..00000000 --- a/kassette.imock.setsaveforwardedrequestdata.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setSaveForwardedRequestData](./kassette.imock.setsaveforwardedrequestdata.md) - -## IMock.setSaveForwardedRequestData() method - -Sets the [saveForwardedRequestData](./kassette.imock.saveforwardedrequestdata.md) value. - -**Signature:** - -```typescript -setSaveForwardedRequestData(value: boolean | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | boolean \| null | whether to save the forwarded request data (headers, method, URL) when creating a new mock for this request. Passing null resets the value to the default coming from [the global setting](./kassette.cliconfigurationspec.saveforwardedrequestdata.md). | - -**Returns:** - -void - diff --git a/kassette.imock.setsaveinputrequestbody.md b/kassette.imock.setsaveinputrequestbody.md deleted file mode 100644 index 1560c7d1..00000000 --- a/kassette.imock.setsaveinputrequestbody.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setSaveInputRequestBody](./kassette.imock.setsaveinputrequestbody.md) - -## IMock.setSaveInputRequestBody() method - -Sets the [saveInputRequestBody](./kassette.imock.saveinputrequestbody.md) value. - -**Signature:** - -```typescript -setSaveInputRequestBody(value: boolean | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | boolean \| null | whether to save the content of the input request body when creating a new mock for this request. Passing null resets the value to the default coming from [the global setting](./kassette.cliconfigurationspec.saveinputrequestbody.md). | - -**Returns:** - -void - diff --git a/kassette.imock.setsaveinputrequestdata.md b/kassette.imock.setsaveinputrequestdata.md deleted file mode 100644 index f31429ed..00000000 --- a/kassette.imock.setsaveinputrequestdata.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [setSaveInputRequestData](./kassette.imock.setsaveinputrequestdata.md) - -## IMock.setSaveInputRequestData() method - -Sets the [saveInputRequestData](./kassette.imock.saveinputrequestdata.md) value. - -**Signature:** - -```typescript -setSaveInputRequestData(value: boolean | null): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| value | boolean \| null | whether to save the input request data (headers, method, URL) when creating a new mock for this request. Passing null resets the value to the default coming from [the global setting](./kassette.cliconfigurationspec.saveinputrequestdata.md). | - -**Returns:** - -void - diff --git a/kassette.imock.sourcepayload.md b/kassette.imock.sourcepayload.md deleted file mode 100644 index 783181b5..00000000 --- a/kassette.imock.sourcepayload.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IMock](./kassette.imock.md) > [sourcePayload](./kassette.imock.sourcepayload.md) - -## IMock.sourcePayload property - -As soon as response is filled with a payload, this property holds the reference to that payload's wrapper. The wrapper is useful here to know where the payload comes from. Before that, this property is `undefined`. - -**Signature:** - -```typescript -sourcePayload: PayloadWithOrigin | undefined; -``` diff --git a/kassette.includablespec.include.md b/kassette.includablespec.include.md deleted file mode 100644 index 965ab9b7..00000000 --- a/kassette.includablespec.include.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IncludableSpec](./kassette.includablespec.md) > [include](./kassette.includablespec.include.md) - -## IncludableSpec.include property - -Whether to include this piece of data in the hash. It is `true` by default (if an object is passed). - -**Signature:** - -```typescript -include?: boolean; -``` diff --git a/kassette.includablespec.md b/kassette.includablespec.md deleted file mode 100644 index 840355aa..00000000 --- a/kassette.includablespec.md +++ /dev/null @@ -1,20 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IncludableSpec](./kassette.includablespec.md) - -## IncludableSpec interface - -Base interface used in [ChecksumArgs](./kassette.checksumargs.md) for each piece of data that can be included or not in the hash computed by the [checksum](./kassette.imock.checksum.md) method. - -**Signature:** - -```typescript -export interface IncludableSpec -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [include?](./kassette.includablespec.include.md) | | boolean | _(Optional)_ Whether to include this piece of data in the hash. It is true by default (if an object is passed). | - diff --git a/kassette.iproxyconnectapi.connection.md b/kassette.iproxyconnectapi.connection.md deleted file mode 100644 index 5c971fa6..00000000 --- a/kassette.iproxyconnectapi.connection.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [connection](./kassette.iproxyconnectapi.connection.md) - -## IProxyConnectAPI.connection property - -The last connection in [connectionsStack](./kassette.iproxyconnectapi.connectionsstack.md) - -**Signature:** - -```typescript -readonly connection: Readonly; -``` diff --git a/kassette.iproxyconnectapi.connectionsstack.md b/kassette.iproxyconnectapi.connectionsstack.md deleted file mode 100644 index ce326ee9..00000000 --- a/kassette.iproxyconnectapi.connectionsstack.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [connectionsStack](./kassette.iproxyconnectapi.connectionsstack.md) - -## IProxyConnectAPI.connectionsStack property - -The connections stack - -**Signature:** - -```typescript -readonly connectionsStack: readonly Readonly[]; -``` diff --git a/kassette.iproxyconnectapi.destinationhostname.md b/kassette.iproxyconnectapi.destinationhostname.md deleted file mode 100644 index 8db1f841..00000000 --- a/kassette.iproxyconnectapi.destinationhostname.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [destinationHostname](./kassette.iproxyconnectapi.destinationhostname.md) - -## IProxyConnectAPI.destinationHostname property - -The destination hostname that will be used in `forward` mode. By default, it is equal to [hostname](./kassette.iproxyconnectapi.hostname.md). Can be changed with [setDestination](./kassette.iproxyconnectapi.setdestination.md). - -**Signature:** - -```typescript -readonly destinationHostname: string; -``` diff --git a/kassette.iproxyconnectapi.destinationport.md b/kassette.iproxyconnectapi.destinationport.md deleted file mode 100644 index 4c4c157f..00000000 --- a/kassette.iproxyconnectapi.destinationport.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [destinationPort](./kassette.iproxyconnectapi.destinationport.md) - -## IProxyConnectAPI.destinationPort property - -The destination port that will be used in `forward` mode. By default, it is equal to [port](./kassette.iproxyconnectapi.port.md). Can be changed with [setDestination](./kassette.iproxyconnectapi.setdestination.md). - -**Signature:** - -```typescript -readonly destinationPort: number; -``` diff --git a/kassette.iproxyconnectapi.hostname.md b/kassette.iproxyconnectapi.hostname.md deleted file mode 100644 index 1f8c5d63..00000000 --- a/kassette.iproxyconnectapi.hostname.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [hostname](./kassette.iproxyconnectapi.hostname.md) - -## IProxyConnectAPI.hostname property - -The target hostname in the CONNECT request - -**Signature:** - -```typescript -readonly hostname: string; -``` diff --git a/kassette.iproxyconnectapi.md b/kassette.iproxyconnectapi.md deleted file mode 100644 index d3eff068..00000000 --- a/kassette.iproxyconnectapi.md +++ /dev/null @@ -1,36 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) - -## IProxyConnectAPI interface - -A handier wrapper around a CONNECT request - -**Signature:** - -```typescript -export interface IProxyConnectAPI -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [connection](./kassette.iproxyconnectapi.connection.md) | readonly | Readonly<[Connection](./kassette.connection.md)> | The last connection in [connectionsStack](./kassette.iproxyconnectapi.connectionsstack.md) | -| [connectionsStack](./kassette.iproxyconnectapi.connectionsstack.md) | readonly | readonly Readonly<[Connection](./kassette.connection.md)>\[\] | The connections stack | -| [destinationHostname](./kassette.iproxyconnectapi.destinationhostname.md) | readonly | string | The destination hostname that will be used in forward mode. By default, it is equal to [hostname](./kassette.iproxyconnectapi.hostname.md). Can be changed with [setDestination](./kassette.iproxyconnectapi.setdestination.md). | -| [destinationPort](./kassette.iproxyconnectapi.destinationport.md) | readonly | number | The destination port that will be used in forward mode. By default, it is equal to [port](./kassette.iproxyconnectapi.port.md). Can be changed with [setDestination](./kassette.iproxyconnectapi.setdestination.md). | -| [hostname](./kassette.iproxyconnectapi.hostname.md) | readonly | string | The target hostname in the CONNECT request | -| [mode](./kassette.iproxyconnectapi.mode.md) | readonly | [ProxyConnectMode](./kassette.proxyconnectmode.md) | The currently selected mode, configured either by a call to [setMode](./kassette.iproxyconnectapi.setmode.md) or by [the global setting](./kassette.cliconfigurationspec.proxyconnectmode.md) | -| [port](./kassette.iproxyconnectapi.port.md) | readonly | number | The target port in the CONNECT request | -| [request](./kassette.iproxyconnectapi.request.md) | readonly | IncomingMessage \| Http2ServerRequest | The original Node.js object representing the request | -| [socket](./kassette.iproxyconnectapi.socket.md) | readonly | Socket \| ServerHttp2Stream | The underlying socket | - -## Methods - -| Method | Description | -| --- | --- | -| [process()](./kassette.iproxyconnectapi.process.md) | Processes the socket according to the mode stored in [mode](./kassette.iproxyconnectapi.mode.md). This method is called automatically when the [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) function finishes, but it can also be called manually before. | -| [setDestination(hostname, port)](./kassette.iproxyconnectapi.setdestination.md) | Sets the destination [hostname](./kassette.iproxyconnectapi.destinationhostname.md) and [port](./kassette.iproxyconnectapi.destinationport.md) that will be used when the [process](./kassette.iproxyconnectapi.process.md) method is called. Also changes the [mode](./kassette.iproxyconnectapi.mode.md) to forward. | -| [setMode(mode)](./kassette.iproxyconnectapi.setmode.md) | Changes the [mode](./kassette.iproxyconnectapi.mode.md) that will be used when the [process](./kassette.iproxyconnectapi.process.md) method is called. | - diff --git a/kassette.iproxyconnectapi.mode.md b/kassette.iproxyconnectapi.mode.md deleted file mode 100644 index a8ee08f4..00000000 --- a/kassette.iproxyconnectapi.mode.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [mode](./kassette.iproxyconnectapi.mode.md) - -## IProxyConnectAPI.mode property - -The currently selected mode, configured either by a call to [setMode](./kassette.iproxyconnectapi.setmode.md) or by [the global setting](./kassette.cliconfigurationspec.proxyconnectmode.md) - -**Signature:** - -```typescript -readonly mode: ProxyConnectMode; -``` diff --git a/kassette.iproxyconnectapi.port.md b/kassette.iproxyconnectapi.port.md deleted file mode 100644 index 07e5cc70..00000000 --- a/kassette.iproxyconnectapi.port.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [port](./kassette.iproxyconnectapi.port.md) - -## IProxyConnectAPI.port property - -The target port in the CONNECT request - -**Signature:** - -```typescript -readonly port: number; -``` diff --git a/kassette.iproxyconnectapi.process.md b/kassette.iproxyconnectapi.process.md deleted file mode 100644 index bbcf207f..00000000 --- a/kassette.iproxyconnectapi.process.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [process](./kassette.iproxyconnectapi.process.md) - -## IProxyConnectAPI.process() method - -Processes the socket according to the mode stored in [mode](./kassette.iproxyconnectapi.mode.md). This method is called automatically when the [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) function finishes, but it can also be called manually before. - -**Signature:** - -```typescript -process(): void; -``` -**Returns:** - -void - diff --git a/kassette.iproxyconnectapi.request.md b/kassette.iproxyconnectapi.request.md deleted file mode 100644 index f9e59441..00000000 --- a/kassette.iproxyconnectapi.request.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [request](./kassette.iproxyconnectapi.request.md) - -## IProxyConnectAPI.request property - -The original Node.js object representing the request - -**Signature:** - -```typescript -readonly request: IncomingMessage | Http2ServerRequest; -``` diff --git a/kassette.iproxyconnectapi.setdestination.md b/kassette.iproxyconnectapi.setdestination.md deleted file mode 100644 index c91551b3..00000000 --- a/kassette.iproxyconnectapi.setdestination.md +++ /dev/null @@ -1,25 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [setDestination](./kassette.iproxyconnectapi.setdestination.md) - -## IProxyConnectAPI.setDestination() method - -Sets the destination [hostname](./kassette.iproxyconnectapi.destinationhostname.md) and [port](./kassette.iproxyconnectapi.destinationport.md) that will be used when the [process](./kassette.iproxyconnectapi.process.md) method is called. Also changes the [mode](./kassette.iproxyconnectapi.mode.md) to `forward`. - -**Signature:** - -```typescript -setDestination(hostname: string, port: number): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| hostname | string | Destination hostname | -| port | number | Destination port | - -**Returns:** - -void - diff --git a/kassette.iproxyconnectapi.setmode.md b/kassette.iproxyconnectapi.setmode.md deleted file mode 100644 index 21c7d855..00000000 --- a/kassette.iproxyconnectapi.setmode.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [setMode](./kassette.iproxyconnectapi.setmode.md) - -## IProxyConnectAPI.setMode() method - -Changes the [mode](./kassette.iproxyconnectapi.mode.md) that will be used when the [process](./kassette.iproxyconnectapi.process.md) method is called. - -**Signature:** - -```typescript -setMode(mode: ProxyConnectMode): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| mode | [ProxyConnectMode](./kassette.proxyconnectmode.md) | mode to set | - -**Returns:** - -void - diff --git a/kassette.iproxyconnectapi.socket.md b/kassette.iproxyconnectapi.socket.md deleted file mode 100644 index ed4466a1..00000000 --- a/kassette.iproxyconnectapi.socket.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IProxyConnectAPI](./kassette.iproxyconnectapi.md) > [socket](./kassette.iproxyconnectapi.socket.md) - -## IProxyConnectAPI.socket property - -The underlying socket - -**Signature:** - -```typescript -readonly socket: Socket | ServerHttp2Stream; -``` diff --git a/kassette.iresponse.body.md b/kassette.iresponse.body.md deleted file mode 100644 index d0ce8f60..00000000 --- a/kassette.iresponse.body.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IResponse](./kassette.iresponse.md) > [body](./kassette.iresponse.body.md) - -## IResponse.body property - -The body of the response. - -**Signature:** - -```typescript -body: any; -``` - -## Remarks - -If `json` is explicitly set to `true`, it will be serialized into JSON (and `content-type` header will be set to `application/json`). It will also be if `json` is not explicitly set but the `body` value is not a string, not a `Buffer`, and not `null` either. After that, the result will eventually be converted to a `Buffer` to be sent. - diff --git a/kassette.iresponse.headers.md b/kassette.iresponse.headers.md deleted file mode 100644 index 01573a64..00000000 --- a/kassette.iresponse.headers.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IResponse](./kassette.iresponse.md) > [headers](./kassette.iresponse.headers.md) - -## IResponse.headers property - -The currently set headers. Use [setHeaders](./kassette.iresponse.setheaders.md) to change them. - -**Signature:** - -```typescript -readonly headers: Readonly; -``` diff --git a/kassette.iresponse.json.md b/kassette.iresponse.json.md deleted file mode 100644 index 095d0b5d..00000000 --- a/kassette.iresponse.json.md +++ /dev/null @@ -1,18 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IResponse](./kassette.iresponse.md) > [json](./kassette.iresponse.json.md) - -## IResponse.json property - -Whether the [body](./kassette.iresponse.body.md) field should be serialized into JSON (and `content-type` header should be set to `application/json`). - -**Signature:** - -```typescript -json: boolean; -``` - -## Remarks - -When not explicitly set, the returned value will still be true if the `body` value is not a string, not a `Buffer`, and not `null` either. - diff --git a/kassette.iresponse.md b/kassette.iresponse.md deleted file mode 100644 index 72a07f25..00000000 --- a/kassette.iresponse.md +++ /dev/null @@ -1,32 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IResponse](./kassette.iresponse.md) - -## IResponse interface - -A handier wrapper around a server response - -**Signature:** - -```typescript -export interface IResponse -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [body](./kassette.iresponse.body.md) | | any | The body of the response. | -| [headers](./kassette.iresponse.headers.md) | readonly | Readonly<IncomingHttpHeaders> | The currently set headers. Use [setHeaders](./kassette.iresponse.setheaders.md) to change them. | -| [json](./kassette.iresponse.json.md) | | boolean | Whether the [body](./kassette.iresponse.body.md) field should be serialized into JSON (and content-type header should be set to application/json). | -| [original](./kassette.iresponse.original.md) | readonly | ServerResponse \| Http2ServerResponse | The original Node.js object representing the response | -| [status](./kassette.iresponse.status.md) | | Partial<Readonly<[Status](./kassette.status.md)>> \| null | An object {code, message}, where each property is optional. If code is never given, a default value of 200 is applied. | - -## Methods - -| Method | Description | -| --- | --- | -| [send()](./kassette.iresponse.send.md) | Sends the response, applying some data previously specified but not set yet | -| [setData(data)](./kassette.iresponse.setdata.md) | A convenient method to set the [body](./kassette.iresponse.body.md) value and set [json](./kassette.iresponse.json.md) to true. | -| [setHeaders(headers)](./kassette.iresponse.setheaders.md) | Merge given headers map with the previously set headers (initial set is an empty map). | - diff --git a/kassette.iresponse.original.md b/kassette.iresponse.original.md deleted file mode 100644 index 41549715..00000000 --- a/kassette.iresponse.original.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IResponse](./kassette.iresponse.md) > [original](./kassette.iresponse.original.md) - -## IResponse.original property - -The original Node.js object representing the response - -**Signature:** - -```typescript -readonly original: ServerResponse | Http2ServerResponse; -``` diff --git a/kassette.iresponse.send.md b/kassette.iresponse.send.md deleted file mode 100644 index cc7dd105..00000000 --- a/kassette.iresponse.send.md +++ /dev/null @@ -1,17 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IResponse](./kassette.iresponse.md) > [send](./kassette.iresponse.send.md) - -## IResponse.send() method - -Sends the response, applying some data previously specified but not set yet - -**Signature:** - -```typescript -send(): Promise; -``` -**Returns:** - -Promise<void> - diff --git a/kassette.iresponse.setdata.md b/kassette.iresponse.setdata.md deleted file mode 100644 index 9fb6d8b2..00000000 --- a/kassette.iresponse.setdata.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IResponse](./kassette.iresponse.md) > [setData](./kassette.iresponse.setdata.md) - -## IResponse.setData() method - -A convenient method to set the [body](./kassette.iresponse.body.md) value and set [json](./kassette.iresponse.json.md) to `true`. - -**Signature:** - -```typescript -setData(data: any): void; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| data | any | json object to use as the response body | - -**Returns:** - -void - diff --git a/kassette.iresponse.setheaders.md b/kassette.iresponse.setheaders.md deleted file mode 100644 index 196ab759..00000000 --- a/kassette.iresponse.setheaders.md +++ /dev/null @@ -1,24 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IResponse](./kassette.iresponse.md) > [setHeaders](./kassette.iresponse.setheaders.md) - -## IResponse.setHeaders() method - -Merge given `headers` map with the previously set headers (initial set is an empty map). - -**Signature:** - -```typescript -setHeaders(headers?: Readonly): Readonly; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| headers | Readonly<IncomingHttpHeaders> | _(Optional)_ Headers to set. Each header value can be a number, a string, or an array of strings. Put a null value to suppress a header | - -**Returns:** - -Readonly<IncomingHttpHeaders> - diff --git a/kassette.iresponse.status.md b/kassette.iresponse.status.md deleted file mode 100644 index c9580d53..00000000 --- a/kassette.iresponse.status.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [IResponse](./kassette.iresponse.md) > [status](./kassette.iresponse.status.md) - -## IResponse.status property - -An object `{code, message}`, where each property is optional. If `code` is never given, a default value of `200` is applied. - -**Signature:** - -```typescript -status: Partial> | null; -``` diff --git a/kassette.listorfilter.md b/kassette.listorfilter.md deleted file mode 100644 index 0a93ea26..00000000 --- a/kassette.listorfilter.md +++ /dev/null @@ -1,34 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ListOrFilter](./kassette.listorfilter.md) - -## ListOrFilter type - -Type used in [ChecksumArgs](./kassette.checksumargs.md) for each piece of data that has a map structure, such as the query and headers, to specify if and how they are included in the hash computed by the [checksum](./kassette.imock.checksum.md) method. - -**Signature:** - -```typescript -export type ListOrFilter = FilterableSpec, any> | (IncludableSpec & { - caseSensitive?: boolean; -} & ({} | { - mode?: 'whitelist' | 'blacklist'; - keys: string[]; -})); -``` -**References:** [FilterableSpec](./kassette.filterablespec.md), [IncludableSpec](./kassette.includablespec.md) - -## Remarks - -This can be an object with the following properties: - -- `include`: `true` or `false` as defined in [IncludableSpec](./kassette.includablespec.include.md) - -- `filter`: a function as defined in [FilterableSpec](./kassette.filterablespec.filter.md). Note that if filter is provided, the other options below are ignored. - -- `caseSensitive`: whether keys should be treated case sensitive or not. `true` by default. When set to `false`, the output object contains lower cased keys. - -- `keys`: a list of keys to keep if in `whitelist` mode or to reject if in `blacklist` mode. If `caseSensitive` is `false`, comparison of keys is not case sensitive. If `keys` is not specified, all keys are included by default. - -- `mode`: `whitelist` (default) or `blacklist` - diff --git a/kassette.md b/kassette.md deleted file mode 100644 index b783f741..00000000 --- a/kassette.md +++ /dev/null @@ -1,66 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) - -## kassette package - -kassette is a development server, used mainly for testing, which proxies requests and is able to easily manage local mocks. - -## Functions - -| Function | Description | -| --- | --- | -| [runFromAPI(options)](./kassette.runfromapi.md) | Launch the proxy programmatically. | - -## Interfaces - -| Interface | Description | -| --- | --- | -| [APIOptions](./kassette.apioptions.md) | Specifies the argument expected to start kassette programmatically with [runFromAPI()](./kassette.runfromapi.md). | -| [ChecksumArgs](./kassette.checksumargs.md) | Type of the argument expected by [checksum](./kassette.imock.checksum.md). It specifies which data from the request to include in the checksum. | -| [CLIConfigurationSpec](./kassette.cliconfigurationspec.md) | The set of possible properties defined through the CLI (it is reduced since it can't contain runtime values) | -| [ConfigurationSpec](./kassette.configurationspec.md) | Augments the CLI spec to add all pure runtime properties, that can be defined through the configuration file only | -| [Connection](./kassette.connection.md) | A connection intercepted by kassette | -| [ConsoleSpec](./kassette.consolespec.md) | Console with logging methods. | -| [FilterableSpec](./kassette.filterablespec.md) | Interface used in [ChecksumArgs](./kassette.checksumargs.md) for each piece of data that can be filtered (i.e. modified) before it is included in the hash computed by the [checksum](./kassette.imock.checksum.md) method. | -| [GetConfigurationProps](./kassette.getconfigurationprops.md) | Parameter of the [getConfiguration](./kassette.iconfigurationfile.getconfiguration.md) function (which a kassette configuration file is supposed to export). | -| [HarFormatContent](./kassette.harformatcontent.md) | Information about the response body, as stored in a har file. | -| [HarFormatEntry](./kassette.harformatentry.md) | Detailed information about a request and its response, as stored in a har file. | -| [HarFormatNameValuePair](./kassette.harformatnamevaluepair.md) | Information about a header or a query parameter, as stored in a har file. | -| [HarFormatPostData](./kassette.harformatpostdata.md) | Information about a request body, as stored in a har file. | -| [HarFormatRequest](./kassette.harformatrequest.md) | Detailed information about a request, as stored in a har file. | -| [HarFormatResponse](./kassette.harformatresponse.md) | Detailed information about a response, as stored in a har file. | -| [HarFormatTimings](./kassette.harformattimings.md) | Details about the time spent for each phase of a request-response round trip, as stored in a har file. | -| [HookAPI](./kassette.hookapi.md) | Parameter of the [hook](./kassette.configurationspec.hook.md) callback, that is called for every HTTP request that kassette receives. | -| [IConfigurationFile](./kassette.iconfigurationfile.md) | Interface that a kassette configuration file should export. | -| [IConfigurationProperty](./kassette.iconfigurationproperty.md) | Contains the value and origin of a configuration property. | -| [IFetchedRequest](./kassette.ifetchedrequest.md) | A handier wrapper around a request | -| [IMock](./kassette.imock.md) |

The public interface exposed to the end user to handle a given request and the associated mock and response.

An object implementing this interface is passed to the [hook](./kassette.configurationspec.hook.md) function, under property mock of the single argument object.

| -| [IncludableSpec](./kassette.includablespec.md) | Base interface used in [ChecksumArgs](./kassette.checksumargs.md) for each piece of data that can be included or not in the hash computed by the [checksum](./kassette.imock.checksum.md) method. | -| [IProxyConnectAPI](./kassette.iproxyconnectapi.md) | A handier wrapper around a CONNECT request | -| [IResponse](./kassette.iresponse.md) | A handier wrapper around a server response | -| [MockData](./kassette.mockdata.md) | The data representing the mock, which is persisted and used for serving the mock | -| [MockingOptions](./kassette.mockingoptions.md) | Configuration options, including the root folder used to resolve relative paths and the current global configuration. | -| [Payload](./kassette.payload.md) | The payload represents the content of an HTTP response from the backend, no matter if it actually comes from it or if it was created manually. | -| [PayloadWithOrigin](./kassette.payloadwithorigin.md) | Contains the payload along with its origin. | -| [RemotePayload](./kassette.remotepayload.md) | Remote payload and the request that was made to get it. | -| [RequestPayload](./kassette.requestpayload.md) | Content of an HTTP request. | -| [RequestTimings](./kassette.requesttimings.md) | Details about the time spent for each phase of a request-response round trip. All times are specified in milliseconds. | -| [Status](./kassette.status.md) | The response status | - -## Type Aliases - -| Type Alias | Description | -| --- | --- | -| [ConfigurationPropertySource](./kassette.configurationpropertysource.md) | The id of the source of the resolved value. | -| [Delay](./kassette.delay.md) | Delay that will be used to send the response to the client when the data is taken from the local mock. | -| [HarKeyManager](./kassette.harkeymanager.md) | Each entry in a har file is supposed to have a corresponding unique key (a string). The har key manager is both a getter and a setter for the key of an entry. | -| [Headers\_2](./kassette.headers_2.md) | A map from strings to strings or array of strings | -| [IMergedConfiguration](./kassette.imergedconfiguration.md) | The resulting configuration that was merged from its different [sources](./kassette.configurationpropertysource.md). | -| [ListOrFilter](./kassette.listorfilter.md) | Type used in [ChecksumArgs](./kassette.checksumargs.md) for each piece of data that has a map structure, such as the query and headers, to specify if and how they are included in the hash computed by the [checksum](./kassette.imock.checksum.md) method. | -| [MocksFormat](./kassette.mocksformat.md) | Specifies the mocks format to use. It can be defined globally through the [mocksFormat](./kassette.cliconfigurationspec.mocksformat.md) setting or per-request from the [hook](./kassette.configurationspec.hook.md) method through [setMocksFormat](./kassette.imock.setmocksformat.md). | -| [Mode](./kassette.mode.md) | The main working mode of the proxy. It can be defined globally through the [mode](./kassette.cliconfigurationspec.mode.md) setting or per-request from the [hook](./kassette.configurationspec.hook.md) method through [setMode](./kassette.imock.setmode.md). | -| [PayloadOrigin](./kassette.payloadorigin.md) | Origin of the payload. | -| [ProxyConnectMode](./kassette.proxyconnectmode.md) | The mode describing how to process CONNECT requests. It can be defined globally through the [proxyConnectMode](./kassette.cliconfigurationspec.proxyconnectmode.md) setting or per-request from the [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) method through [setMode](./kassette.iproxyconnectapi.setmode.md). | -| [RecursiveArray](./kassette.recursivearray.md) | A single value or a virtually unlimitedly nested array of this type of value | - diff --git a/kassette.mockdata.bodyfilename.md b/kassette.mockdata.bodyfilename.md deleted file mode 100644 index 4ef03c64..00000000 --- a/kassette.mockdata.bodyfilename.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockData](./kassette.mockdata.md) > [bodyFileName](./kassette.mockdata.bodyfilename.md) - -## MockData.bodyFileName property - -The name of the local file containing the body content (needed since the name is dynamic) - -**Signature:** - -```typescript -readonly bodyFileName: string; -``` diff --git a/kassette.mockdata.creationdatetime.md b/kassette.mockdata.creationdatetime.md deleted file mode 100644 index e377d86f..00000000 --- a/kassette.mockdata.creationdatetime.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockData](./kassette.mockdata.md) > [creationDateTime](./kassette.mockdata.creationdatetime.md) - -## MockData.creationDateTime property - -Timestamp when the payload was created. - -**Signature:** - -```typescript -readonly creationDateTime?: Date; -``` diff --git a/kassette.mockdata.headers.md b/kassette.mockdata.headers.md deleted file mode 100644 index d8548398..00000000 --- a/kassette.mockdata.headers.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockData](./kassette.mockdata.md) > [headers](./kassette.mockdata.headers.md) - -## MockData.headers property - -Recorded headers to be served back, without the ignored ones. - -**Signature:** - -```typescript -readonly headers?: Readonly; -``` diff --git a/kassette.mockdata.httpversion.md b/kassette.mockdata.httpversion.md deleted file mode 100644 index 8b257e02..00000000 --- a/kassette.mockdata.httpversion.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockData](./kassette.mockdata.md) > [httpVersion](./kassette.mockdata.httpversion.md) - -## MockData.httpVersion property - -Http version of the server when the mock was recorded. Will most likely be '1.1' or perhaps '1.0'. It is not used when replaying responses. - -**Signature:** - -```typescript -readonly httpVersion?: string; -``` diff --git a/kassette.mockdata.ignoredheaders.md b/kassette.mockdata.ignoredheaders.md deleted file mode 100644 index c14337f6..00000000 --- a/kassette.mockdata.ignoredheaders.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockData](./kassette.mockdata.md) > [ignoredHeaders](./kassette.mockdata.ignoredheaders.md) - -## MockData.ignoredHeaders property - -Ignored headers, which are recorded headers that should not be served back. In practice, this is mainly the `content-length` header (because the `content-length` header that is actually served back is computed based on the actual data to send). - -**Signature:** - -```typescript -readonly ignoredHeaders?: Readonly; -``` diff --git a/kassette.mockdata.md b/kassette.mockdata.md deleted file mode 100644 index c5b1f050..00000000 --- a/kassette.mockdata.md +++ /dev/null @@ -1,27 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockData](./kassette.mockdata.md) - -## MockData interface - -The data representing the mock, which is persisted and used for serving the mock - -**Signature:** - -```typescript -export interface MockData -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [bodyFileName](./kassette.mockdata.bodyfilename.md) | readonly | string | The name of the local file containing the body content (needed since the name is dynamic) | -| [creationDateTime?](./kassette.mockdata.creationdatetime.md) | readonly | Date | _(Optional)_ Timestamp when the payload was created. | -| [headers?](./kassette.mockdata.headers.md) | readonly | Readonly<IncomingHttpHeaders> | _(Optional)_ Recorded headers to be served back, without the ignored ones. | -| [httpVersion?](./kassette.mockdata.httpversion.md) | readonly | string | _(Optional)_ Http version of the server when the mock was recorded. Will most likely be '1.1' or perhaps '1.0'. It is not used when replaying responses. | -| [ignoredHeaders?](./kassette.mockdata.ignoredheaders.md) | readonly | Readonly<IncomingHttpHeaders> | _(Optional)_ Ignored headers, which are recorded headers that should not be served back. In practice, this is mainly the content-length header (because the content-length header that is actually served back is computed based on the actual data to send). | -| [status](./kassette.mockdata.status.md) | readonly | Readonly<[Status](./kassette.status.md)> | HTTP status. | -| [time](./kassette.mockdata.time.md) | readonly | number | Time used by the server to process the request. It is used to simulate the real processing time when mocking the server if the [delay](./kassette.cliconfigurationspec.delay.md) is set to recorded. | -| [timings?](./kassette.mockdata.timings.md) | readonly | [RequestTimings](./kassette.requesttimings.md) | _(Optional)_ Detailed timings recorded during the request. | - diff --git a/kassette.mockdata.status.md b/kassette.mockdata.status.md deleted file mode 100644 index 2941574f..00000000 --- a/kassette.mockdata.status.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockData](./kassette.mockdata.md) > [status](./kassette.mockdata.status.md) - -## MockData.status property - -HTTP status. - -**Signature:** - -```typescript -readonly status: Readonly; -``` diff --git a/kassette.mockdata.time.md b/kassette.mockdata.time.md deleted file mode 100644 index 85182b5f..00000000 --- a/kassette.mockdata.time.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockData](./kassette.mockdata.md) > [time](./kassette.mockdata.time.md) - -## MockData.time property - -Time used by the server to process the request. It is used to simulate the real processing time when mocking the server if the [delay](./kassette.cliconfigurationspec.delay.md) is set to `recorded`. - -**Signature:** - -```typescript -readonly time: number; -``` diff --git a/kassette.mockdata.timings.md b/kassette.mockdata.timings.md deleted file mode 100644 index b2cd5879..00000000 --- a/kassette.mockdata.timings.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockData](./kassette.mockdata.md) > [timings](./kassette.mockdata.timings.md) - -## MockData.timings property - -Detailed timings recorded during the request. - -**Signature:** - -```typescript -readonly timings?: RequestTimings; -``` diff --git a/kassette.mockingoptions.md b/kassette.mockingoptions.md deleted file mode 100644 index 2b469af8..00000000 --- a/kassette.mockingoptions.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockingOptions](./kassette.mockingoptions.md) - -## MockingOptions interface - -Configuration options, including the root folder used to resolve relative paths and the current global configuration. - -**Signature:** - -```typescript -export interface MockingOptions -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [root](./kassette.mockingoptions.root.md) | readonly | string | The root folder from which to resolve given relative paths | -| [userConfiguration](./kassette.mockingoptions.userconfiguration.md) | readonly | [IMergedConfiguration](./kassette.imergedconfiguration.md) | The current global user configuration | - diff --git a/kassette.mockingoptions.root.md b/kassette.mockingoptions.root.md deleted file mode 100644 index afc10b22..00000000 --- a/kassette.mockingoptions.root.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockingOptions](./kassette.mockingoptions.md) > [root](./kassette.mockingoptions.root.md) - -## MockingOptions.root property - -The root folder from which to resolve given relative paths - -**Signature:** - -```typescript -readonly root: string; -``` diff --git a/kassette.mockingoptions.userconfiguration.md b/kassette.mockingoptions.userconfiguration.md deleted file mode 100644 index 9e3bfe87..00000000 --- a/kassette.mockingoptions.userconfiguration.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MockingOptions](./kassette.mockingoptions.md) > [userConfiguration](./kassette.mockingoptions.userconfiguration.md) - -## MockingOptions.userConfiguration property - -The current global user configuration - -**Signature:** - -```typescript -readonly userConfiguration: IMergedConfiguration; -``` diff --git a/kassette.mocksformat.md b/kassette.mocksformat.md deleted file mode 100644 index 502aa771..00000000 --- a/kassette.mocksformat.md +++ /dev/null @@ -1,22 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [MocksFormat](./kassette.mocksformat.md) - -## MocksFormat type - -Specifies the mocks format to use. It can be defined globally through the [mocksFormat](./kassette.cliconfigurationspec.mocksformat.md) setting or per-request from the [hook](./kassette.configurationspec.hook.md) method through [setMocksFormat](./kassette.imock.setmocksformat.md). - -**Signature:** - -```typescript -export type MocksFormat = 'folder' | 'har'; -``` - -## Remarks - -Here are the two possible formats: - -- the `folder` format is specific to kassette and stores each request with its response in one folder containing up to 7 files: `data.json` (headers, status code and message of the response, as specified in [MockData](./kassette.mockdata.md)), `body.[ext]` (content of the body of the backend response), `input-request.json` (headers, method, URL and body file name of the input request, from client to proxy, for debug), `input-request-body.[ext]` (content of the body of the input request), `forwarded-request.json` (headers, method, URL, whether body was eventually a string or a Buffer and body file name of the forwarded request, from proxy to backend, for debug), `forwarded-request-body.[ext]` (the content of the body of the forwarded request), `checksum` (if a checksum was computed, the content generated to compute it). `[ext]` is an extension computed based on the actual type of the content in the file. - -- the `har` [format](http://www.softwareishard.com/blog/har-12-spec) is supported [by several other tools](http://www.softwareishard.com/blog/har-adopters/) and can store multiple requests with their responses in a single (json-based) file. In this file, each request/response couple follows the structure specified in [HarFormatEntry](./kassette.harformatentry.md). - diff --git a/kassette.mode.md b/kassette.mode.md deleted file mode 100644 index 358bdcb6..00000000 --- a/kassette.mode.md +++ /dev/null @@ -1,30 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Mode](./kassette.mode.md) - -## Mode type - -The main working mode of the proxy. It can be defined globally through the [mode](./kassette.cliconfigurationspec.mode.md) setting or per-request from the [hook](./kassette.configurationspec.hook.md) method through [setMode](./kassette.imock.setmode.md). - -**Signature:** - -```typescript -export type Mode = 'local' | 'remote' | 'download' | 'local_or_remote' | 'local_or_download' | 'manual'; -``` - -## Remarks - -The mode drives how [getPayloadAndFillResponse](./kassette.imock.getpayloadandfillresponse.md) and [process](./kassette.imock.process.md) will behave. Here are the possible modes: - -- `manual`: don't do anything, leaving the responsibility to the user to call proper APIs to manage local files and/or backend querying, and response filling - -- `remote`: forward the request to the remote backend and never touch the local mock - -- `download`: get payload from remote backend by forwarding request, create the local mock from this payload, and fill the response with it - -- `local_or_remote`: if local mock exists, read it and fill the response with it, if local mock doesn't exist, do as for `remote` mode - -- `local_or_download`: if local mock exists, read it and fill the response with it, if local mock doesn't exist, do as for `download` mode - -- `local`: if local mock exists, read it and fill the response with it, if local mock doesn't exist, create a minimal payload with a 404 status code, do not persist it and fill the response with it - diff --git a/kassette.payload.body.md b/kassette.payload.body.md deleted file mode 100644 index 14baa005..00000000 --- a/kassette.payload.body.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Payload](./kassette.payload.md) > [body](./kassette.payload.body.md) - -## Payload.body property - -Body of the HTTP response. - -**Signature:** - -```typescript -body: Buffer | string | null; -``` diff --git a/kassette.payload.data.md b/kassette.payload.data.md deleted file mode 100644 index 31480d0b..00000000 --- a/kassette.payload.data.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Payload](./kassette.payload.md) > [data](./kassette.payload.data.md) - -## Payload.data property - -Data such as http status and headers, response delay. - -**Signature:** - -```typescript -data: MockData; -``` diff --git a/kassette.payload.md b/kassette.payload.md deleted file mode 100644 index 907b9490..00000000 --- a/kassette.payload.md +++ /dev/null @@ -1,29 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Payload](./kassette.payload.md) - -## Payload interface - -The payload represents the content of an HTTP response from the backend, no matter if it actually comes from it or if it was created manually. - -**Signature:** - -```typescript -export interface Payload -``` - -## Remarks - -A payload is often wrapped in [PayloadWithOrigin](./kassette.payloadwithorigin.md). To create the wrapped payload, you can use [createPayload](./kassette.imock.createpayload.md). - -From the wrapped payload, response to the client can be filled with [fillResponseFromPayload](./kassette.imock.fillresponsefrompayload.md). - -The payload can also be persisted and read, to avoid contacting the backend later on. - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [body](./kassette.payload.body.md) | | Buffer \| string \| null | Body of the HTTP response. | -| [data](./kassette.payload.data.md) | | [MockData](./kassette.mockdata.md) | Data such as http status and headers, response delay. | - diff --git a/kassette.payloadorigin.md b/kassette.payloadorigin.md deleted file mode 100644 index 038d11ff..00000000 --- a/kassette.payloadorigin.md +++ /dev/null @@ -1,26 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [PayloadOrigin](./kassette.payloadorigin.md) - -## PayloadOrigin type - -Origin of the payload. - -**Signature:** - -```typescript -export type PayloadOrigin = 'local' | 'proxy' | 'remote' | 'user'; -``` - -## Remarks - -Here are the possible values: - -- `local`: if the payload was read from local mock - -- `remote`: if the payload was fetched from the remote backend by forwarding the request - -- `user`: if the payload has been created from the user, manually using [createPayload](./kassette.imock.createpayload.md) - -- `proxy`: if the payload has been created from kassette itself, especially for `404 Not found` errors (in `local` mode) and `502 Bad Gateway` errors (when kassette cannot reach the remote server) - diff --git a/kassette.payloadwithorigin.md b/kassette.payloadwithorigin.md deleted file mode 100644 index 36ef6a69..00000000 --- a/kassette.payloadwithorigin.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [PayloadWithOrigin](./kassette.payloadwithorigin.md) - -## PayloadWithOrigin interface - -Contains the payload along with its origin. - -**Signature:** - -```typescript -export interface PayloadWithOrigin -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [origin](./kassette.payloadwithorigin.origin.md) | | Origin | Origin of the payload. | -| [payload](./kassette.payloadwithorigin.payload.md) | | [Payload](./kassette.payload.md) | Content of the payload. | - diff --git a/kassette.payloadwithorigin.origin.md b/kassette.payloadwithorigin.origin.md deleted file mode 100644 index df121f93..00000000 --- a/kassette.payloadwithorigin.origin.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [PayloadWithOrigin](./kassette.payloadwithorigin.md) > [origin](./kassette.payloadwithorigin.origin.md) - -## PayloadWithOrigin.origin property - -Origin of the payload. - -**Signature:** - -```typescript -origin: Origin; -``` diff --git a/kassette.payloadwithorigin.payload.md b/kassette.payloadwithorigin.payload.md deleted file mode 100644 index a1a287f3..00000000 --- a/kassette.payloadwithorigin.payload.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [PayloadWithOrigin](./kassette.payloadwithorigin.md) > [payload](./kassette.payloadwithorigin.payload.md) - -## PayloadWithOrigin.payload property - -Content of the payload. - -**Signature:** - -```typescript -payload: Payload; -``` diff --git a/kassette.proxyconnectmode.md b/kassette.proxyconnectmode.md deleted file mode 100644 index 8a0e83f7..00000000 --- a/kassette.proxyconnectmode.md +++ /dev/null @@ -1,26 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [ProxyConnectMode](./kassette.proxyconnectmode.md) - -## ProxyConnectMode type - -The mode describing how to process `CONNECT` requests. It can be defined globally through the [proxyConnectMode](./kassette.cliconfigurationspec.proxyconnectmode.md) setting or per-request from the [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) method through [setMode](./kassette.iproxyconnectapi.setmode.md). - -**Signature:** - -```typescript -export type ProxyConnectMode = 'close' | 'intercept' | 'forward' | 'manual'; -``` - -## Remarks - -Here are the possible modes for `CONNECT` requests: - -- `intercept`: kassette answers with `HTTP/1.1 200 Connection established` and pretends to be the target server. If the browser then makes http or https requests on the socket after this `CONNECT` request, they will be processed by kassette and pass through the [hook](./kassette.configurationspec.hook.md) method (if any). That's the default mode. - -- `forward`: kassette blindly connects to the remote destination [hostname](./kassette.iproxyconnectapi.hostname.md) and [port](./kassette.iproxyconnectapi.port.md) specified in the `CONNECT` request and forwards all data in both directions. This is what a normal proxy server is supposed to do. The destination hostname and port can optionally be modified in the [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) method through the [setDestination](./kassette.iproxyconnectapi.setdestination.md) method. - -- `close`: kassette simply closes the underlying socket. This is what servers which do not support the `CONNECT` method do. - -- `manual`: kassette does nothing special with the socket, leaving it in its current state. This setting allows to use any custom logic in the [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) callback. It only makes sense if the [onProxyConnect](./kassette.configurationspec.onproxyconnect.md) callback is implemented, otherwise the browser will wait indefinitely for an answer. - diff --git a/kassette.recursivearray.md b/kassette.recursivearray.md deleted file mode 100644 index 17358139..00000000 --- a/kassette.recursivearray.md +++ /dev/null @@ -1,15 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RecursiveArray](./kassette.recursivearray.md) - -## RecursiveArray type - -A single value or a virtually unlimitedly nested array of this type of value - -**Signature:** - -```typescript -export type RecursiveArray = T | Array>; -``` -**References:** [RecursiveArray](./kassette.recursivearray.md) - diff --git a/kassette.remotepayload.md b/kassette.remotepayload.md deleted file mode 100644 index b9b83c44..00000000 --- a/kassette.remotepayload.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RemotePayload](./kassette.remotepayload.md) - -## RemotePayload interface - -Remote payload and the request that was made to get it. - -**Signature:** - -```typescript -export interface RemotePayload extends PayloadWithOrigin<'remote'> -``` -**Extends:** [PayloadWithOrigin](./kassette.payloadwithorigin.md)<'remote'> - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [requestOptions](./kassette.remotepayload.requestoptions.md) | | [RequestPayload](./kassette.requestpayload.md) | Request used to get this remote payload. | - diff --git a/kassette.remotepayload.requestoptions.md b/kassette.remotepayload.requestoptions.md deleted file mode 100644 index cf5b028e..00000000 --- a/kassette.remotepayload.requestoptions.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RemotePayload](./kassette.remotepayload.md) > [requestOptions](./kassette.remotepayload.requestoptions.md) - -## RemotePayload.requestOptions property - -Request used to get this remote payload. - -**Signature:** - -```typescript -requestOptions: RequestPayload; -``` diff --git a/kassette.requestpayload.body.md b/kassette.requestpayload.body.md deleted file mode 100644 index b8a1e0de..00000000 --- a/kassette.requestpayload.body.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestPayload](./kassette.requestpayload.md) > [body](./kassette.requestpayload.body.md) - -## RequestPayload.body property - -HTTP request body - -**Signature:** - -```typescript -body?: string | Buffer; -``` diff --git a/kassette.requestpayload.headers.md b/kassette.requestpayload.headers.md deleted file mode 100644 index a91374cb..00000000 --- a/kassette.requestpayload.headers.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestPayload](./kassette.requestpayload.md) > [headers](./kassette.requestpayload.headers.md) - -## RequestPayload.headers property - -HTTP headers - -**Signature:** - -```typescript -headers: IncomingHttpHeaders; -``` diff --git a/kassette.requestpayload.md b/kassette.requestpayload.md deleted file mode 100644 index d27e7cc8..00000000 --- a/kassette.requestpayload.md +++ /dev/null @@ -1,23 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestPayload](./kassette.requestpayload.md) - -## RequestPayload interface - -Content of an HTTP request. - -**Signature:** - -```typescript -export interface RequestPayload -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [body?](./kassette.requestpayload.body.md) | | string \| Buffer | _(Optional)_ HTTP request body | -| [headers](./kassette.requestpayload.headers.md) | | IncomingHttpHeaders | HTTP headers | -| [method](./kassette.requestpayload.method.md) | | string | HTTP method | -| [url](./kassette.requestpayload.url.md) | | string | HTTP url | - diff --git a/kassette.requestpayload.method.md b/kassette.requestpayload.method.md deleted file mode 100644 index d5fb8599..00000000 --- a/kassette.requestpayload.method.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestPayload](./kassette.requestpayload.md) > [method](./kassette.requestpayload.method.md) - -## RequestPayload.method property - -HTTP method - -**Signature:** - -```typescript -method: string; -``` diff --git a/kassette.requestpayload.url.md b/kassette.requestpayload.url.md deleted file mode 100644 index 8c567189..00000000 --- a/kassette.requestpayload.url.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestPayload](./kassette.requestpayload.md) > [url](./kassette.requestpayload.url.md) - -## RequestPayload.url property - -HTTP url - -**Signature:** - -```typescript -url: string; -``` diff --git a/kassette.requesttimings.blocked.md b/kassette.requesttimings.blocked.md deleted file mode 100644 index f78635fd..00000000 --- a/kassette.requesttimings.blocked.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestTimings](./kassette.requesttimings.md) > [blocked](./kassette.requesttimings.blocked.md) - -## RequestTimings.blocked property - -Time spent in a queue waiting for a network connection. Can be -1 if the timing does not apply to the current request. - -**Signature:** - -```typescript -blocked?: number; -``` diff --git a/kassette.requesttimings.connect.md b/kassette.requesttimings.connect.md deleted file mode 100644 index 8719cdfc..00000000 --- a/kassette.requesttimings.connect.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestTimings](./kassette.requesttimings.md) > [connect](./kassette.requesttimings.connect.md) - -## RequestTimings.connect property - -Time required to create TCP connection. Can be -1 if the timing does not apply to the current request. - -**Signature:** - -```typescript -connect?: number; -``` diff --git a/kassette.requesttimings.dns.md b/kassette.requesttimings.dns.md deleted file mode 100644 index ffef7617..00000000 --- a/kassette.requesttimings.dns.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestTimings](./kassette.requesttimings.md) > [dns](./kassette.requesttimings.dns.md) - -## RequestTimings.dns property - -The time required to resolve a host name. Can be -1 if the timing does not apply to the current request. - -**Signature:** - -```typescript -dns?: number; -``` diff --git a/kassette.requesttimings.md b/kassette.requesttimings.md deleted file mode 100644 index 5b7586b4..00000000 --- a/kassette.requesttimings.md +++ /dev/null @@ -1,26 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestTimings](./kassette.requesttimings.md) - -## RequestTimings interface - -Details about the time spent for each phase of a request-response round trip. All times are specified in milliseconds. - -**Signature:** - -```typescript -export interface RequestTimings -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [blocked?](./kassette.requesttimings.blocked.md) | | number | _(Optional)_ Time spent in a queue waiting for a network connection. Can be -1 if the timing does not apply to the current request. | -| [connect?](./kassette.requesttimings.connect.md) | | number | _(Optional)_ Time required to create TCP connection. Can be -1 if the timing does not apply to the current request. | -| [dns?](./kassette.requesttimings.dns.md) | | number | _(Optional)_ The time required to resolve a host name. Can be -1 if the timing does not apply to the current request. | -| [receive?](./kassette.requesttimings.receive.md) | | number | _(Optional)_ Time required to read entire response from the server. | -| [send?](./kassette.requesttimings.send.md) | | number | _(Optional)_ Time required to send HTTP request to the server. | -| [ssl?](./kassette.requesttimings.ssl.md) | | number | _(Optional)_ Time required for SSL/TLS negotiation. This time is also included in the [RequestTimings.connect](./kassette.requesttimings.connect.md) field. Can be -1 if the timing does not apply to the current request. | -| [wait?](./kassette.requesttimings.wait.md) | | number | _(Optional)_ Time waiting for a response from the server. | - diff --git a/kassette.requesttimings.receive.md b/kassette.requesttimings.receive.md deleted file mode 100644 index 5835993b..00000000 --- a/kassette.requesttimings.receive.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestTimings](./kassette.requesttimings.md) > [receive](./kassette.requesttimings.receive.md) - -## RequestTimings.receive property - -Time required to read entire response from the server. - -**Signature:** - -```typescript -receive?: number; -``` diff --git a/kassette.requesttimings.send.md b/kassette.requesttimings.send.md deleted file mode 100644 index 0e0bddc7..00000000 --- a/kassette.requesttimings.send.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestTimings](./kassette.requesttimings.md) > [send](./kassette.requesttimings.send.md) - -## RequestTimings.send property - -Time required to send HTTP request to the server. - -**Signature:** - -```typescript -send?: number; -``` diff --git a/kassette.requesttimings.ssl.md b/kassette.requesttimings.ssl.md deleted file mode 100644 index ade4563e..00000000 --- a/kassette.requesttimings.ssl.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestTimings](./kassette.requesttimings.md) > [ssl](./kassette.requesttimings.ssl.md) - -## RequestTimings.ssl property - -Time required for SSL/TLS negotiation. This time is also included in the [RequestTimings.connect](./kassette.requesttimings.connect.md) field. Can be -1 if the timing does not apply to the current request. - -**Signature:** - -```typescript -ssl?: number; -``` diff --git a/kassette.requesttimings.wait.md b/kassette.requesttimings.wait.md deleted file mode 100644 index 6a67e6c4..00000000 --- a/kassette.requesttimings.wait.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [RequestTimings](./kassette.requesttimings.md) > [wait](./kassette.requesttimings.wait.md) - -## RequestTimings.wait property - -Time waiting for a response from the server. - -**Signature:** - -```typescript -wait?: number; -``` diff --git a/kassette.runfromapi.md b/kassette.runfromapi.md deleted file mode 100644 index 1aa290f7..00000000 --- a/kassette.runfromapi.md +++ /dev/null @@ -1,26 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [runFromAPI](./kassette.runfromapi.md) - -## runFromAPI() function - -Launch the proxy programmatically. - -**Signature:** - -```typescript -export declare function runFromAPI(options: APIOptions): Promise<() => void>; -``` - -## Parameters - -| Parameter | Type | Description | -| --- | --- | --- | -| options | [APIOptions](./kassette.apioptions.md) | kassette configuration options | - -**Returns:** - -Promise<() => void> - -a callback that can be used to shutdown the proxy, calling the [onExit](./kassette.configurationspec.onexit.md) callback defined in configuration (if provided). - diff --git a/kassette.status.code.md b/kassette.status.code.md deleted file mode 100644 index 39f9fc45..00000000 --- a/kassette.status.code.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Status](./kassette.status.md) > [code](./kassette.status.code.md) - -## Status.code property - -The status code - -**Signature:** - -```typescript -code: number; -``` diff --git a/kassette.status.md b/kassette.status.md deleted file mode 100644 index 63eb9a5d..00000000 --- a/kassette.status.md +++ /dev/null @@ -1,21 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Status](./kassette.status.md) - -## Status interface - -The response status - -**Signature:** - -```typescript -export interface Status -``` - -## Properties - -| Property | Modifiers | Type | Description | -| --- | --- | --- | --- | -| [code](./kassette.status.code.md) | | number | The status code | -| [message](./kassette.status.message.md) | | string | The status message | - diff --git a/kassette.status.message.md b/kassette.status.message.md deleted file mode 100644 index 2701664f..00000000 --- a/kassette.status.message.md +++ /dev/null @@ -1,13 +0,0 @@ - - -[Home](./index.md) > [@amadeus-it-group/kassette](./kassette.md) > [Status](./kassette.status.md) > [message](./kassette.status.message.md) - -## Status.message property - -The status message - -**Signature:** - -```typescript -message: string; -``` diff --git a/modules.html b/modules.html new file mode 100644 index 00000000..58e92898 --- /dev/null +++ b/modules.html @@ -0,0 +1,45 @@ +@amadeus-it-group/kassette

Generated using TypeDoc

\ No newline at end of file diff --git a/types/ConfigurationPropertySource.html b/types/ConfigurationPropertySource.html new file mode 100644 index 00000000..51448bb4 --- /dev/null +++ b/types/ConfigurationPropertySource.html @@ -0,0 +1,2 @@ +ConfigurationPropertySource | @amadeus-it-group/kassette

Generated using TypeDoc

\ No newline at end of file diff --git a/types/Delay.html b/types/Delay.html new file mode 100644 index 00000000..fecbb557 --- /dev/null +++ b/types/Delay.html @@ -0,0 +1,6 @@ +Delay | @amadeus-it-group/kassette
Delay: "recorded" | number

Delay that will be used to send the response to the client +when the data is taken from the local mock.

+

Remarks

It can be expressed either as a direct value (in milliseconds) or as the +'recorded' string, which means to use the delay recorded +in the local mock (in the time field).

+

Generated using TypeDoc

\ No newline at end of file diff --git a/types/HarKeyManager.html b/types/HarKeyManager.html new file mode 100644 index 00000000..c085566f --- /dev/null +++ b/types/HarKeyManager.html @@ -0,0 +1,21 @@ +HarKeyManager | @amadeus-it-group/kassette
HarKeyManager: ((entry, key?) => RecursiveArray<string | null | undefined>)

Type declaration

    • (entry, key?): RecursiveArray<string | null | undefined>
    • Each entry in a har file is supposed to have a corresponding unique key (a string). +The har key manager is both a getter and a setter for the key of an entry.

      +

      Parameters

      Returns RecursiveArray<string | null | undefined>

      Remarks

      The har key manager is a function that is called either to get the key of an entry (when +the key parameter is undefined) or to set it (when the key parameter is defined).

      +

      It should not modify the entry when the key parameter is undefined.

      +

      When the key parameter is defined, the har key manager is supposed to change the provided entry, in order to store the +key in it, because after the call, the entry will be persisted in the har file. In this case, the key parameter either +comes from a call to IMock.setMockHarKey, or from defaultMockHarKey.

      +

      In order to compute the defaultMockHarKey property, the har key manager +is called with an entry that includes the request but not the response (and with an undefined key parameter).

      +

      In all cases, the har key manager is expected to return the key of the entry. If an array is returned (which can +be nested), it is flattened with null items removed, and joined with forward slashes to produce a string.

      +

      The default har key manager is expected to work fine for most use cases, especially when working with a har file recorded +with kassette. With the default har key manager, if a key is set with IMock.setMockHarKey, it is stored in the +_kassetteMockKey field. Otherwise, the default key is the concatenation of the request +method and url, with a separating forward slash. It can be useful to replace the default har key manager with a custom one especially +when working with har files that are produced by other applications than kassette, if the default key is not convenient.

      +

      Example

      Here is the default har key manager:

      +
      export const defaultHarKeyManager: HarKeyManager = (entry: HarFormatEntry, key?: string) => {
      const defaultKey = joinPath(entry._kassetteMockKey ?? [entry.request?.method, entry.request?.url]);
      if (key && key !== defaultKey) {
      entry._kassetteMockKey = key;
      return key;
      }
      return defaultKey;
      }; +
      +

Generated using TypeDoc

\ No newline at end of file diff --git a/types/Headers.html b/types/Headers.html new file mode 100644 index 00000000..c8997f98 --- /dev/null +++ b/types/Headers.html @@ -0,0 +1,2 @@ +Headers | @amadeus-it-group/kassette

Generated using TypeDoc

\ No newline at end of file diff --git a/types/IMergedConfiguration.html b/types/IMergedConfiguration.html new file mode 100644 index 00000000..226ef6f7 --- /dev/null +++ b/types/IMergedConfiguration.html @@ -0,0 +1,6 @@ +IMergedConfiguration | @amadeus-it-group/kassette

Type alias IMergedConfiguration

IMergedConfiguration: {
    filePath: string | null;
} & {
    readonly [k in keyof ConfigurationSpec]-?: IConfigurationProperty<Required<ConfigurationSpec>[k]>
}

The resulting configuration that was merged from its different sources.

+

Type declaration

  • Readonly filePath: string | null

    The path of the configuration file

    +

Remarks

It contains the path to the configuration file in filePath, and also for each property defined in ConfigurationSpec, +there is an IConfigurationProperty object describing the origin of the property +and its value.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/types/ListOrFilter.html b/types/ListOrFilter.html new file mode 100644 index 00000000..19f01763 --- /dev/null +++ b/types/ListOrFilter.html @@ -0,0 +1,17 @@ +ListOrFilter | @amadeus-it-group/kassette
ListOrFilter: FilterableSpec<Record<string, any>, any> | IncludableSpec & {
    caseSensitive?: boolean;
} & ({} | {
    keys: string[];
    mode?: "whitelist" | "blacklist";
})

Type used in ChecksumArgs for each piece of data that has a map structure, such as the query and headers, +to specify if and how they are included in the hash computed by the checksum method.

+

Remarks

This can be an object with the following properties:

+
    +
  • include: true or false as defined in IncludableSpec

    +
  • +
  • filter: a function as defined in FilterableSpec. Note that if filter is provided, the other options below are ignored.

    +
  • +
  • caseSensitive: whether keys should be treated case sensitive or not. true by default. When set to false, the output object contains lower cased keys.

    +
  • +
  • keys: a list of keys to keep if in whitelist mode or to reject if in blacklist mode. If caseSensitive is false, comparison of keys is not case sensitive. +If keys is not specified, all keys are included by default.

    +
  • +
  • mode: whitelist (default) or blacklist

    +
  • +
+

Generated using TypeDoc

\ No newline at end of file diff --git a/types/MocksFormat.html b/types/MocksFormat.html new file mode 100644 index 00000000..2035c974 --- /dev/null +++ b/types/MocksFormat.html @@ -0,0 +1,25 @@ +MocksFormat | @amadeus-it-group/kassette
MocksFormat: "folder" | "har"

Specifies the mocks format to use. It can be defined globally through +the mocksFormat setting +or per-request from the hook method through +setMocksFormat.

+

Remarks

Here are the two possible formats:

+
    +
  • the folder format is specific to kassette and stores each request with its response in +one folder containing up to 7 files: +data.json (headers, status code and message of the response, as specified in MockData), +body.[ext] (content of the body of the backend response), +input-request.json (headers, method, URL and body file name of the input request, from client to proxy, for debug), +input-request-body.[ext] (content of the body of the input request), +forwarded-request.json (headers, method, URL, whether body was eventually a string or a Buffer and body file name +of the forwarded request, from proxy to backend, for debug), +forwarded-request-body.[ext] (the content of the body of the forwarded request), +checksum (if a checksum was computed, the content generated to compute it). +[ext] is an extension computed based on the actual type of the content in the file.

    +
  • +
  • the har format is supported +by several other tools and can store +multiple requests with their responses in a single (json-based) file. In this file, each +request/response couple follows the structure specified in HarFormatEntry.

    +
  • +
+

Generated using TypeDoc

\ No newline at end of file diff --git a/types/Mode.html b/types/Mode.html new file mode 100644 index 00000000..7e8757d8 --- /dev/null +++ b/types/Mode.html @@ -0,0 +1,24 @@ +Mode | @amadeus-it-group/kassette
Mode: "local" | "remote" | "download" | "local_or_remote" | "local_or_download" | "manual"

The main working mode of the proxy. It can be defined globally through +the mode setting +or per-request from the hook method through +setMode.

+

Remarks

The mode drives how getPayloadAndFillResponse and process +will behave. Here are the possible modes:

+
    +
  • manual: don't do anything, leaving the responsibility to the user to call proper APIs to manage local files and/or +backend querying, and response filling

    +
  • +
  • remote: forward the request to the remote backend and never touch the local mock

    +
  • +
  • download: get payload from remote backend by forwarding request, create the local mock from this payload, and fill +the response with it

    +
  • +
  • local_or_remote: if local mock exists, read it and fill the response with it, if local mock doesn't exist, do as for remote mode

    +
  • +
  • local_or_download: if local mock exists, read it and fill the response with it, if local mock doesn't exist, do as for download mode

    +
  • +
  • local: if local mock exists, read it and fill the response with it, if local mock doesn't exist, create a minimal payload with a 404 status +code, do not persist it and fill the response with it

    +
  • +
+

Generated using TypeDoc

\ No newline at end of file diff --git a/types/PayloadOrigin.html b/types/PayloadOrigin.html new file mode 100644 index 00000000..a8d8af3f --- /dev/null +++ b/types/PayloadOrigin.html @@ -0,0 +1,14 @@ +PayloadOrigin | @amadeus-it-group/kassette
PayloadOrigin: "local" | "proxy" | "remote" | "user"

Origin of the payload.

+

Remarks

Here are the possible values:

+
    +
  • local: if the payload was read from local mock

    +
  • +
  • remote: if the payload was fetched from the remote backend by forwarding the request

    +
  • +
  • user: if the payload has been created from the user, manually using createPayload

    +
  • +
  • proxy: if the payload has been created from kassette itself, especially for 404 Not found errors (in local mode) +and 502 Bad Gateway errors (when kassette cannot reach the remote server)

    +
  • +
+

Generated using TypeDoc

\ No newline at end of file diff --git a/types/ProxyConnectMode.html b/types/ProxyConnectMode.html new file mode 100644 index 00000000..07ebbdbb --- /dev/null +++ b/types/ProxyConnectMode.html @@ -0,0 +1,16 @@ +ProxyConnectMode | @amadeus-it-group/kassette
ProxyConnectMode: "close" | "intercept" | "forward" | "manual"

The mode describing how to process CONNECT requests. It can be defined globally through +the proxyConnectMode setting +or per-request from the onProxyConnect method through +setMode.

+

Remarks

Here are the possible modes for CONNECT requests:

+
    +
  • intercept: kassette answers with HTTP/1.1 200 Connection established and pretends to be the target server. If the browser then makes http or https requests on the socket after this CONNECT request, they will be processed by kassette and pass through the hook method (if any). That's the default mode.

    +
  • +
  • forward: kassette blindly connects to the remote destination hostname and port specified in the CONNECT request and forwards all data in both directions. This is what a normal proxy server is supposed to do. The destination hostname and port can optionally be modified in the onProxyConnect method through the setDestination method.

    +
  • +
  • close: kassette simply closes the underlying socket. This is what servers which do not support the CONNECT method do.

    +
  • +
  • manual: kassette does nothing special with the socket, leaving it in its current state. This setting allows to use any custom logic in the onProxyConnect callback. It only makes sense if the onProxyConnect callback is implemented, otherwise the browser will wait indefinitely for an answer.

    +
  • +
+

Generated using TypeDoc

\ No newline at end of file diff --git a/types/RecursiveArray.html b/types/RecursiveArray.html new file mode 100644 index 00000000..b7f4aa63 --- /dev/null +++ b/types/RecursiveArray.html @@ -0,0 +1,2 @@ +RecursiveArray | @amadeus-it-group/kassette

Generated using TypeDoc

\ No newline at end of file