ibm-cloud-sdk-core 4.3.2-beta-2 → 4.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (252) hide show
  1. package/.cra/.cveignore +2 -0
  2. package/.secrets.baseline +590 -0
  3. package/Authentication.md +600 -0
  4. package/CHANGELOG.md +886 -0
  5. package/LICENSE.md +201 -0
  6. package/MIGRATION-V4.md +54 -0
  7. package/README.md +118 -0
  8. package/api-extractor.json +39 -0
  9. package/appscan-config.xml +8 -0
  10. package/build/docs/ibm-cloud-sdk-core.atleastone.md +71 -0
  11. package/build/docs/ibm-cloud-sdk-core.atmostone.md +71 -0
  12. package/build/docs/ibm-cloud-sdk-core.authenticator._constructor_.md +18 -0
  13. package/build/docs/ibm-cloud-sdk-core.authenticator.authenticate.md +57 -0
  14. package/build/docs/ibm-cloud-sdk-core.authenticator.authenticationtype.md +19 -0
  15. package/build/docs/ibm-cloud-sdk-core.authenticator.authtype_basic.md +13 -0
  16. package/build/docs/ibm-cloud-sdk-core.authenticator.authtype_bearertoken.md +11 -0
  17. package/build/docs/ibm-cloud-sdk-core.authenticator.authtype_container.md +11 -0
  18. package/build/docs/ibm-cloud-sdk-core.authenticator.authtype_cp4d.md +11 -0
  19. package/build/docs/ibm-cloud-sdk-core.authenticator.authtype_iam.md +11 -0
  20. package/build/docs/ibm-cloud-sdk-core.authenticator.authtype_mcsp.md +11 -0
  21. package/build/docs/ibm-cloud-sdk-core.authenticator.authtype_noauth.md +11 -0
  22. package/build/docs/ibm-cloud-sdk-core.authenticator.authtype_unknown.md +11 -0
  23. package/build/docs/ibm-cloud-sdk-core.authenticator.authtype_vpc.md +11 -0
  24. package/build/docs/ibm-cloud-sdk-core.authenticator.md +294 -0
  25. package/build/docs/ibm-cloud-sdk-core.authenticatorinterface.authenticate.md +53 -0
  26. package/build/docs/ibm-cloud-sdk-core.authenticatorinterface.authenticationtype.md +17 -0
  27. package/build/docs/ibm-cloud-sdk-core.authenticatorinterface.md +50 -0
  28. package/build/docs/ibm-cloud-sdk-core.baseservice._constructor_.md +49 -0
  29. package/build/docs/ibm-cloud-sdk-core.baseservice.baseoptions.md +11 -0
  30. package/build/docs/ibm-cloud-sdk-core.baseservice.configureservice.md +53 -0
  31. package/build/docs/ibm-cloud-sdk-core.baseservice.convertmodel.md +85 -0
  32. package/build/docs/ibm-cloud-sdk-core.baseservice.createrequest.md +55 -0
  33. package/build/docs/ibm-cloud-sdk-core.baseservice.createrequestanddeserializeresponse.md +87 -0
  34. package/build/docs/ibm-cloud-sdk-core.baseservice.default_service_name.md +11 -0
  35. package/build/docs/ibm-cloud-sdk-core.baseservice.default_service_url.md +11 -0
  36. package/build/docs/ibm-cloud-sdk-core.baseservice.disableretries.md +17 -0
  37. package/build/docs/ibm-cloud-sdk-core.baseservice.enableretries.md +53 -0
  38. package/build/docs/ibm-cloud-sdk-core.baseservice.getauthenticator.md +19 -0
  39. package/build/docs/ibm-cloud-sdk-core.baseservice.gethttpclient.md +17 -0
  40. package/build/docs/ibm-cloud-sdk-core.baseservice.md +313 -0
  41. package/build/docs/ibm-cloud-sdk-core.baseservice.setdefaultheaders.md +53 -0
  42. package/build/docs/ibm-cloud-sdk-core.baseservice.setenablegzipcompression.md +53 -0
  43. package/build/docs/ibm-cloud-sdk-core.baseservice.setserviceurl.md +53 -0
  44. package/build/docs/ibm-cloud-sdk-core.basicauthenticator._constructor_.md +54 -0
  45. package/build/docs/ibm-cloud-sdk-core.basicauthenticator.authenticate.md +55 -0
  46. package/build/docs/ibm-cloud-sdk-core.basicauthenticator.authenticationtype.md +19 -0
  47. package/build/docs/ibm-cloud-sdk-core.basicauthenticator.authheader.md +13 -0
  48. package/build/docs/ibm-cloud-sdk-core.basicauthenticator.md +165 -0
  49. package/build/docs/ibm-cloud-sdk-core.basicauthenticator.requiredoptions.md +11 -0
  50. package/build/docs/ibm-cloud-sdk-core.bearertokenauthenticator._constructor_.md +54 -0
  51. package/build/docs/ibm-cloud-sdk-core.bearertokenauthenticator.authenticate.md +55 -0
  52. package/build/docs/ibm-cloud-sdk-core.bearertokenauthenticator.authenticationtype.md +19 -0
  53. package/build/docs/ibm-cloud-sdk-core.bearertokenauthenticator.md +160 -0
  54. package/build/docs/ibm-cloud-sdk-core.bearertokenauthenticator.requiredoptions.md +11 -0
  55. package/build/docs/ibm-cloud-sdk-core.bearertokenauthenticator.setbearertoken.md +53 -0
  56. package/build/docs/ibm-cloud-sdk-core.buildrequestfileobject.md +55 -0
  57. package/build/docs/ibm-cloud-sdk-core.checkcredentials.md +71 -0
  58. package/build/docs/ibm-cloud-sdk-core.cloudpakfordataauthenticator._constructor_.md +54 -0
  59. package/build/docs/ibm-cloud-sdk-core.cloudpakfordataauthenticator.authenticationtype.md +19 -0
  60. package/build/docs/ibm-cloud-sdk-core.cloudpakfordataauthenticator.md +149 -0
  61. package/build/docs/ibm-cloud-sdk-core.cloudpakfordataauthenticator.requiredoptions.md +11 -0
  62. package/build/docs/ibm-cloud-sdk-core.cloudpakfordataauthenticator.tokenmanager.md +11 -0
  63. package/build/docs/ibm-cloud-sdk-core.computebasicauthheader.md +71 -0
  64. package/build/docs/ibm-cloud-sdk-core.constructfilepath.md +49 -0
  65. package/build/docs/ibm-cloud-sdk-core.constructserviceurl.md +87 -0
  66. package/build/docs/ibm-cloud-sdk-core.containerauthenticator._constructor_.md +54 -0
  67. package/build/docs/ibm-cloud-sdk-core.containerauthenticator.authenticationtype.md +19 -0
  68. package/build/docs/ibm-cloud-sdk-core.containerauthenticator.md +172 -0
  69. package/build/docs/ibm-cloud-sdk-core.containerauthenticator.setcrtokenfilename.md +53 -0
  70. package/build/docs/ibm-cloud-sdk-core.containerauthenticator.setiamprofileid.md +53 -0
  71. package/build/docs/ibm-cloud-sdk-core.containerauthenticator.setiamprofilename.md +53 -0
  72. package/build/docs/ibm-cloud-sdk-core.containerauthenticator.tokenmanager.md +11 -0
  73. package/build/docs/ibm-cloud-sdk-core.containertokenmanager._constructor_.md +54 -0
  74. package/build/docs/ibm-cloud-sdk-core.containertokenmanager.getcrtoken.md +19 -0
  75. package/build/docs/ibm-cloud-sdk-core.containertokenmanager.md +142 -0
  76. package/build/docs/ibm-cloud-sdk-core.containertokenmanager.requesttoken.md +17 -0
  77. package/build/docs/ibm-cloud-sdk-core.containertokenmanager.setcrtokenfilename.md +53 -0
  78. package/build/docs/ibm-cloud-sdk-core.containertokenmanager.setiamprofileid.md +53 -0
  79. package/build/docs/ibm-cloud-sdk-core.containertokenmanager.setiamprofilename.md +53 -0
  80. package/build/docs/ibm-cloud-sdk-core.contenttype.md +14 -0
  81. package/build/docs/ibm-cloud-sdk-core.cp4dtokenmanager._constructor_.md +54 -0
  82. package/build/docs/ibm-cloud-sdk-core.cp4dtokenmanager.md +128 -0
  83. package/build/docs/ibm-cloud-sdk-core.cp4dtokenmanager.requesttoken.md +15 -0
  84. package/build/docs/ibm-cloud-sdk-core.cp4dtokenmanager.requiredoptions.md +11 -0
  85. package/build/docs/ibm-cloud-sdk-core.fileexistsatpath.md +49 -0
  86. package/build/docs/ibm-cloud-sdk-core.fileobject.md +80 -0
  87. package/build/docs/ibm-cloud-sdk-core.fileobject.options.md +11 -0
  88. package/build/docs/ibm-cloud-sdk-core.fileobject.value.md +11 -0
  89. package/build/docs/ibm-cloud-sdk-core.fileoptions.contenttype.md +11 -0
  90. package/build/docs/ibm-cloud-sdk-core.fileoptions.filename.md +11 -0
  91. package/build/docs/ibm-cloud-sdk-core.fileoptions.md +74 -0
  92. package/build/docs/ibm-cloud-sdk-core.filestream.md +54 -0
  93. package/build/docs/ibm-cloud-sdk-core.filestream.path.md +11 -0
  94. package/build/docs/ibm-cloud-sdk-core.filewithmetadata.contenttype.md +11 -0
  95. package/build/docs/ibm-cloud-sdk-core.filewithmetadata.data.md +11 -0
  96. package/build/docs/ibm-cloud-sdk-core.filewithmetadata.filename.md +11 -0
  97. package/build/docs/ibm-cloud-sdk-core.filewithmetadata.md +87 -0
  98. package/build/docs/ibm-cloud-sdk-core.getauthenticatorfromenvironment.md +55 -0
  99. package/build/docs/ibm-cloud-sdk-core.getcontenttype.md +55 -0
  100. package/build/docs/ibm-cloud-sdk-core.getcurrenttime.md +19 -0
  101. package/build/docs/ibm-cloud-sdk-core.getformat.md +69 -0
  102. package/build/docs/ibm-cloud-sdk-core.getmissingparams.md +73 -0
  103. package/build/docs/ibm-cloud-sdk-core.getnewlogger.md +59 -0
  104. package/build/docs/ibm-cloud-sdk-core.getqueryparam.md +71 -0
  105. package/build/docs/ibm-cloud-sdk-core.iamauthenticator._constructor_.md +54 -0
  106. package/build/docs/ibm-cloud-sdk-core.iamauthenticator.authenticationtype.md +19 -0
  107. package/build/docs/ibm-cloud-sdk-core.iamauthenticator.md +149 -0
  108. package/build/docs/ibm-cloud-sdk-core.iamauthenticator.requiredoptions.md +11 -0
  109. package/build/docs/ibm-cloud-sdk-core.iamauthenticator.tokenmanager.md +11 -0
  110. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedauthenticator._constructor_.md +54 -0
  111. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedauthenticator.clientid.md +11 -0
  112. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedauthenticator.clientsecret.md +11 -0
  113. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedauthenticator.getrefreshtoken.md +19 -0
  114. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedauthenticator.md +211 -0
  115. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedauthenticator.scope.md +11 -0
  116. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedauthenticator.setclientidandsecret.md +69 -0
  117. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedauthenticator.setscope.md +53 -0
  118. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedauthenticator.tokenmanager.md +11 -0
  119. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedtokenmanager._constructor_.md +54 -0
  120. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedtokenmanager.formdata.md +11 -0
  121. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedtokenmanager.getrefreshtoken.md +19 -0
  122. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedtokenmanager.istokenexpired.md +19 -0
  123. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedtokenmanager.md +221 -0
  124. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedtokenmanager.refreshtoken.md +11 -0
  125. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedtokenmanager.requesttoken.md +19 -0
  126. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedtokenmanager.savetokeninfo.md +53 -0
  127. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedtokenmanager.setclientidandsecret.md +69 -0
  128. package/build/docs/ibm-cloud-sdk-core.iamrequestbasedtokenmanager.setscope.md +53 -0
  129. package/build/docs/ibm-cloud-sdk-core.iamrequestoptions.clientid.md +11 -0
  130. package/build/docs/ibm-cloud-sdk-core.iamrequestoptions.clientsecret.md +11 -0
  131. package/build/docs/ibm-cloud-sdk-core.iamrequestoptions.md +96 -0
  132. package/build/docs/ibm-cloud-sdk-core.iamrequestoptions.scope.md +11 -0
  133. package/build/docs/ibm-cloud-sdk-core.iamtokenmanager._constructor_.md +54 -0
  134. package/build/docs/ibm-cloud-sdk-core.iamtokenmanager.md +92 -0
  135. package/build/docs/ibm-cloud-sdk-core.iamtokenmanager.requiredoptions.md +11 -0
  136. package/build/docs/ibm-cloud-sdk-core.isemptyobject.md +49 -0
  137. package/build/docs/ibm-cloud-sdk-core.isfiledata.md +49 -0
  138. package/build/docs/ibm-cloud-sdk-core.isfilewithmetadata.md +49 -0
  139. package/build/docs/ibm-cloud-sdk-core.ishtml.md +55 -0
  140. package/build/docs/ibm-cloud-sdk-core.isjsonmimetype.md +55 -0
  141. package/build/docs/ibm-cloud-sdk-core.jwttokenmanager._constructor_.md +49 -0
  142. package/build/docs/ibm-cloud-sdk-core.jwttokenmanager.md +163 -0
  143. package/build/docs/ibm-cloud-sdk-core.jwttokenmanager.requesttoken.md +19 -0
  144. package/build/docs/ibm-cloud-sdk-core.jwttokenmanager.savetokeninfo.md +53 -0
  145. package/build/docs/ibm-cloud-sdk-core.jwttokenmanager.tokeninfo.md +11 -0
  146. package/build/docs/ibm-cloud-sdk-core.jwttokenmanager.tokenname.md +11 -0
  147. package/build/docs/ibm-cloud-sdk-core.jwttokenmanageroptions.md +15 -0
  148. package/build/docs/ibm-cloud-sdk-core.mcspauthenticator._constructor_.md +54 -0
  149. package/build/docs/ibm-cloud-sdk-core.mcspauthenticator.authenticationtype.md +19 -0
  150. package/build/docs/ibm-cloud-sdk-core.mcspauthenticator.md +145 -0
  151. package/build/docs/ibm-cloud-sdk-core.mcspauthenticator.requiredoptions.md +11 -0
  152. package/build/docs/ibm-cloud-sdk-core.mcspauthenticator.tokenmanager.md +11 -0
  153. package/build/docs/ibm-cloud-sdk-core.mcsptokenmanager._constructor_.md +54 -0
  154. package/build/docs/ibm-cloud-sdk-core.mcsptokenmanager.md +128 -0
  155. package/build/docs/ibm-cloud-sdk-core.mcsptokenmanager.requesttoken.md +15 -0
  156. package/build/docs/ibm-cloud-sdk-core.mcsptokenmanager.requiredoptions.md +11 -0
  157. package/build/docs/ibm-cloud-sdk-core.md +818 -0
  158. package/build/docs/ibm-cloud-sdk-core.noauthauthenticator.authenticate.md +49 -0
  159. package/build/docs/ibm-cloud-sdk-core.noauthauthenticator.authenticationtype.md +19 -0
  160. package/build/docs/ibm-cloud-sdk-core.noauthauthenticator.md +60 -0
  161. package/build/docs/ibm-cloud-sdk-core.onlyone.md +71 -0
  162. package/build/docs/ibm-cloud-sdk-core.qs.md +21 -0
  163. package/build/docs/ibm-cloud-sdk-core.readcredentialsfile.md +17 -0
  164. package/build/docs/ibm-cloud-sdk-core.readcrtokenfile.md +49 -0
  165. package/build/docs/ibm-cloud-sdk-core.readexternalsources.md +55 -0
  166. package/build/docs/ibm-cloud-sdk-core.removesuffix.md +71 -0
  167. package/build/docs/ibm-cloud-sdk-core.sdklogger.debug.md +11 -0
  168. package/build/docs/ibm-cloud-sdk-core.sdklogger.error.md +11 -0
  169. package/build/docs/ibm-cloud-sdk-core.sdklogger.info.md +11 -0
  170. package/build/docs/ibm-cloud-sdk-core.sdklogger.md +121 -0
  171. package/build/docs/ibm-cloud-sdk-core.sdklogger.verbose.md +11 -0
  172. package/build/docs/ibm-cloud-sdk-core.sdklogger.warn.md +11 -0
  173. package/build/docs/ibm-cloud-sdk-core.streamtopromise.md +55 -0
  174. package/build/docs/ibm-cloud-sdk-core.striptrailingslash.md +55 -0
  175. package/build/docs/ibm-cloud-sdk-core.tokenmanager._constructor_.md +49 -0
  176. package/build/docs/ibm-cloud-sdk-core.tokenmanager.accesstoken.md +11 -0
  177. package/build/docs/ibm-cloud-sdk-core.tokenmanager.disablesslverification.md +11 -0
  178. package/build/docs/ibm-cloud-sdk-core.tokenmanager.expiretime.md +11 -0
  179. package/build/docs/ibm-cloud-sdk-core.tokenmanager.gettoken.md +17 -0
  180. package/build/docs/ibm-cloud-sdk-core.tokenmanager.headers.md +11 -0
  181. package/build/docs/ibm-cloud-sdk-core.tokenmanager.istokenexpired.md +17 -0
  182. package/build/docs/ibm-cloud-sdk-core.tokenmanager.md +352 -0
  183. package/build/docs/ibm-cloud-sdk-core.tokenmanager.pacedrequesttoken.md +19 -0
  184. package/build/docs/ibm-cloud-sdk-core.tokenmanager.refreshtime.md +11 -0
  185. package/build/docs/ibm-cloud-sdk-core.tokenmanager.requesttoken.md +19 -0
  186. package/build/docs/ibm-cloud-sdk-core.tokenmanager.requestwrapperinstance.md +11 -0
  187. package/build/docs/ibm-cloud-sdk-core.tokenmanager.savetokeninfo.md +53 -0
  188. package/build/docs/ibm-cloud-sdk-core.tokenmanager.setdisablesslverification.md +53 -0
  189. package/build/docs/ibm-cloud-sdk-core.tokenmanager.setheaders.md +53 -0
  190. package/build/docs/ibm-cloud-sdk-core.tokenmanager.url.md +11 -0
  191. package/build/docs/ibm-cloud-sdk-core.tokenmanager.useragent.md +11 -0
  192. package/build/docs/ibm-cloud-sdk-core.tokenmanageroptions.md +18 -0
  193. package/build/docs/ibm-cloud-sdk-core.tokenrequestbasedauthenticator._constructor_.md +49 -0
  194. package/build/docs/ibm-cloud-sdk-core.tokenrequestbasedauthenticator.authenticate.md +55 -0
  195. package/build/docs/ibm-cloud-sdk-core.tokenrequestbasedauthenticator.disablesslverification.md +11 -0
  196. package/build/docs/ibm-cloud-sdk-core.tokenrequestbasedauthenticator.headers.md +11 -0
  197. package/build/docs/ibm-cloud-sdk-core.tokenrequestbasedauthenticator.md +217 -0
  198. package/build/docs/ibm-cloud-sdk-core.tokenrequestbasedauthenticator.setdisablesslverification.md +53 -0
  199. package/build/docs/ibm-cloud-sdk-core.tokenrequestbasedauthenticator.setheaders.md +53 -0
  200. package/build/docs/ibm-cloud-sdk-core.tokenrequestbasedauthenticator.tokenmanager.md +11 -0
  201. package/build/docs/ibm-cloud-sdk-core.tokenrequestbasedauthenticator.url.md +11 -0
  202. package/build/docs/ibm-cloud-sdk-core.tolowerkeys.md +55 -0
  203. package/build/docs/ibm-cloud-sdk-core.unittestutils.checkforsuccessfulexecution.md +53 -0
  204. package/build/docs/ibm-cloud-sdk-core.unittestutils.checkmediaheaders.md +85 -0
  205. package/build/docs/ibm-cloud-sdk-core.unittestutils.checkurlandmethod.md +85 -0
  206. package/build/docs/ibm-cloud-sdk-core.unittestutils.checkuserheader.md +85 -0
  207. package/build/docs/ibm-cloud-sdk-core.unittestutils.expecttobepromise.md +53 -0
  208. package/build/docs/ibm-cloud-sdk-core.unittestutils.getoptions.md +55 -0
  209. package/build/docs/ibm-cloud-sdk-core.unittestutils.md +86 -0
  210. package/build/docs/ibm-cloud-sdk-core.useroptions.authenticator.md +13 -0
  211. package/build/docs/ibm-cloud-sdk-core.useroptions.disablesslverification.md +13 -0
  212. package/build/docs/ibm-cloud-sdk-core.useroptions.headers.md +13 -0
  213. package/build/docs/ibm-cloud-sdk-core.useroptions.jar.md +13 -0
  214. package/build/docs/ibm-cloud-sdk-core.useroptions.md +171 -0
  215. package/build/docs/ibm-cloud-sdk-core.useroptions.serviceurl.md +13 -0
  216. package/build/docs/ibm-cloud-sdk-core.useroptions.url.md +13 -0
  217. package/build/docs/ibm-cloud-sdk-core.useroptions.version.md +13 -0
  218. package/build/docs/ibm-cloud-sdk-core.validateinput.md +73 -0
  219. package/build/docs/ibm-cloud-sdk-core.validateparams.md +89 -0
  220. package/build/docs/ibm-cloud-sdk-core.vpcinstanceauthenticator._constructor_.md +54 -0
  221. package/build/docs/ibm-cloud-sdk-core.vpcinstanceauthenticator.authenticationtype.md +19 -0
  222. package/build/docs/ibm-cloud-sdk-core.vpcinstanceauthenticator.md +158 -0
  223. package/build/docs/ibm-cloud-sdk-core.vpcinstanceauthenticator.setiamprofilecrn.md +53 -0
  224. package/build/docs/ibm-cloud-sdk-core.vpcinstanceauthenticator.setiamprofileid.md +53 -0
  225. package/build/docs/ibm-cloud-sdk-core.vpcinstanceauthenticator.tokenmanager.md +11 -0
  226. package/build/docs/ibm-cloud-sdk-core.vpcinstancetokenmanager._constructor_.md +54 -0
  227. package/build/docs/ibm-cloud-sdk-core.vpcinstancetokenmanager.istokenexpired.md +19 -0
  228. package/build/docs/ibm-cloud-sdk-core.vpcinstancetokenmanager.md +126 -0
  229. package/build/docs/ibm-cloud-sdk-core.vpcinstancetokenmanager.requesttoken.md +15 -0
  230. package/build/docs/ibm-cloud-sdk-core.vpcinstancetokenmanager.setiamprofilecrn.md +53 -0
  231. package/build/docs/ibm-cloud-sdk-core.vpcinstancetokenmanager.setiamprofileid.md +53 -0
  232. package/build/docs/index.md +29 -0
  233. package/es/lib/sdk-test-helpers.js +1 -2
  234. package/es/tsdoc-metadata.json +11 -0
  235. package/etc/ibm-cloud-sdk-core.api.md +517 -0
  236. package/lib/sdk-test-helpers.js +11 -9
  237. package/package.json +89 -59
  238. package/temp/ibm-cloud-sdk-core.api.json +8641 -0
  239. package/temp/ibm-cloud-sdk-core.api.md +517 -0
  240. package/tsconfig-es6.json +9 -0
  241. package/auth/user-temp/get-authenticator-from-environment.d.ts +0 -28
  242. package/auth/user-temp/get-authenticator-from-environment.js +0 -95
  243. package/auth/user-temp/index.d.ts +0 -25
  244. package/auth/user-temp/index.js +0 -30
  245. package/auth/user-temp/read-external-sources.d.ts +0 -11
  246. package/auth/user-temp/read-external-sources.js +0 -154
  247. package/es/auth/user-temp/get-authenticator-from-environment.d.ts +0 -28
  248. package/es/auth/user-temp/get-authenticator-from-environment.js +0 -91
  249. package/es/auth/user-temp/index.d.ts +0 -25
  250. package/es/auth/user-temp/index.js +0 -25
  251. package/es/auth/user-temp/read-external-sources.d.ts +0 -11
  252. package/es/auth/user-temp/read-external-sources.js +0 -144
@@ -0,0 +1,600 @@
1
+ # Authentication
2
+ The node-sdk-core project supports the following types of authentication:
3
+ - Basic Authentication
4
+ - Bearer Token Authentication
5
+ - Identity and Access Management (IAM) Authentication
6
+ - Container Authentication
7
+ - VPC Instance Authentication
8
+ - Cloud Pak for Data Authentication
9
+ - Multi-Cloud Saas Platform (MCSP) Authentication
10
+ - No Authentication (for testing)
11
+
12
+ The SDK user configures the appropriate type of authentication for use with service instances.
13
+ The authentication types that are appropriate for a particular service may vary from service to service,
14
+ so it is important for the SDK user to consult with the appropriate service documentation to understand
15
+ which authentication types are supported for that service.
16
+
17
+ The node-sdk-core allows an authenticator to be specified in one of two ways:
18
+ 1. programmatically - the SDK user invokes the appropriate function(s) to create an instance of the
19
+ desired authenticator and then passes the authenticator instance when constructing an instance of the service.
20
+ 2. configuration - the SDK user provides external configuration information (in the form of environment variables
21
+ or a credentials file) to indicate the type of authenticator, along with the configuration of the necessary properties
22
+ for that authenticator. The SDK user then invokes the configuration-based authenticator factory to construct an instance
23
+ of the authenticator that is described in the external configuration information.
24
+
25
+ The sections below will provide detailed information for each authenticator
26
+ which will include the following:
27
+ - A description of the authenticator
28
+ - The properties associated with the authenticator
29
+ - An example of how to construct the authenticator programmatically
30
+ - An example of how to configure the authenticator through the use of external
31
+ configuration information. The configuration examples below will use
32
+ environment variables, although the same properties could be specified in a
33
+ credentials file instead.
34
+
35
+
36
+ ## Basic Authentication
37
+ The `BasicAuthenticator` is used to add Basic Authentication information to
38
+ each outbound request in the `Authorization` header in the form:
39
+
40
+ ```
41
+ Authorization: Basic <encoded username and password>
42
+ ```
43
+
44
+ ### Properties
45
+
46
+ - username: (required) the basic auth username
47
+
48
+ - password: (required) the basic auth password
49
+
50
+ ### Programming example
51
+ ```js
52
+ const { BasicAuthenticator } = require('ibm-cloud-sdk-core');
53
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
54
+
55
+ const authenticator = new BasicAuthenticator({
56
+ username: 'myuser',
57
+ password: 'mypassword',
58
+ });
59
+
60
+ const options = {
61
+ authenticator,
62
+ };
63
+
64
+ const service = new ExampleServiceV1(options);
65
+
66
+ // 'service' can now be used to invoke operations.
67
+ ```
68
+
69
+ ### Configuration example
70
+ External configuration:
71
+ ```
72
+ export EXAMPLE_SERVICE_AUTH_TYPE=basic
73
+ export EXAMPLE_SERVICE_USERNAME=myuser
74
+ export EXAMPLE_SERVICE_PASSWORD=mypassword
75
+ ```
76
+ Application code:
77
+ ```js
78
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
79
+
80
+ const options = {
81
+ serviceName: 'example_service',
82
+ };
83
+
84
+ const service = ExampleServiceV1.newInstance(options);
85
+
86
+ // 'service' can now be used to invoke operations.
87
+ ```
88
+
89
+
90
+ ## Bearer Token Authentication
91
+ The `BearerTokenAuthenticator` will add a user-supplied bearer token to
92
+ each outbound request in the `Authorization` header in the form:
93
+
94
+ ```
95
+ Authorization: Bearer <bearer-token>
96
+ ```
97
+
98
+ ### Properties
99
+
100
+ - bearerToken: (required) the bearer token value
101
+
102
+ ### Programming example
103
+ ```js
104
+ const { BearerTokenAuthenticator } = require('ibm-cloud-sdk-core');
105
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
106
+
107
+ const bearerToken = // ... obtain bearer token value ...
108
+ const authenticator = new BearerTokenAuthenticator({
109
+ bearerToken: bearerToken,
110
+ });
111
+
112
+ const options = {
113
+ authenticator,
114
+ };
115
+
116
+ const service = new ExampleServiceV1(options);
117
+
118
+ // 'service' can now be used to invoke operations.
119
+ ...
120
+ // Later, if your bearer token value expires, you can set a new one like this:
121
+ newToken = // ... obtain new bearer token value
122
+ authenticator.bearerToken = newToken;
123
+ ```
124
+
125
+ ### Configuration example
126
+ External configuration:
127
+ ```
128
+ export EXAMPLE_SERVICE_AUTH_TYPE=bearertoken
129
+ export EXAMPLE_SERVICE_BEARER_TOKEN=<the bearer token value>
130
+ ```
131
+ Application code:
132
+ ```js
133
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
134
+
135
+ const options = {
136
+ serviceName: 'example_service',
137
+ };
138
+
139
+ const service = ExampleServiceV1.newInstance(options);
140
+
141
+ // 'service' can now be used to invoke operations.
142
+ ```
143
+
144
+ Note that the use of external configuration is not as useful with the `BearerTokenAuthenticator` as it
145
+ is for other authenticator types because bearer tokens typically need to be obtained and refreshed
146
+ programmatically since they normally have a relatively short lifespan before they expire. This
147
+ authenticator type is intended for situations in which the application will be managing the bearer
148
+ token itself in terms of initial acquisition and refreshing as needed.
149
+
150
+
151
+ ## Identity and Access Management (IAM) Authentication
152
+ The `IamAuthenticator` will accept a user-supplied api key and will perform
153
+ the necessary interactions with the IAM token service to obtain a suitable
154
+ bearer token for the specified api key. The authenticator will also obtain
155
+ a new bearer token when the current token expires. The bearer token is
156
+ then added to each outbound request in the `Authorization` header in the
157
+ form:
158
+ ```
159
+ Authorization: Bearer <bearer-token>
160
+ ```
161
+
162
+ ### Properties
163
+
164
+ - apikey: (required) the IAM api key
165
+
166
+ - url: (optional) The base endpoint URL of the IAM token service.
167
+ The default value of this property is the "prod" IAM token service endpoint
168
+ (`https://iam.cloud.ibm.com`).
169
+ Make sure that you use an IAM token service endpoint that is appropriate for the
170
+ location of the service being used by your application.
171
+ For example, if you are using an instance of a service in the "production" environment
172
+ (e.g. `https://resource-controller.cloud.ibm.com`),
173
+ then the default "prod" IAM token service endpoint should suffice.
174
+ However, if your application is using an instance of a service in the "staging" environment
175
+ (e.g. `https://resource-controller.test.cloud.ibm.com`),
176
+ then you would also need to configure the authenticator to use the IAM token service "staging"
177
+ endpoint as well (`https://iam.test.cloud.ibm.com`).
178
+
179
+ - clientId/clientSecret: (optional) The `clientId` and `clientSecret` fields are used to form a
180
+ "basic auth" Authorization header for interactions with the IAM token server. If neither field
181
+ is specified, then no Authorization header will be sent with token server requests. These fields
182
+ are optional, but must be specified together.
183
+
184
+ - scope: (optional) the scope to be associated with the IAM access token.
185
+ If not specified, then no scope wil be associated with the access token.
186
+
187
+ - disableSslVerification: (optional) A flag that indicates whether verificaton of the server's SSL
188
+ certificate should be disabled or not. The default value is `false`.
189
+
190
+ - headers: (optional) A set of key/value pairs that will be sent as HTTP headers in requests
191
+ made to the IAM token service.
192
+
193
+ ### Programming example
194
+ ```js
195
+ const { IamAuthenticator } = require('ibm-cloud-sdk-core');
196
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
197
+
198
+ const authenticator = new IamAuthenticator({
199
+ apikey: 'myapikey',
200
+ });
201
+
202
+ const options = {
203
+ authenticator,
204
+ };
205
+
206
+ const service = new ExampleServiceV1(options);
207
+
208
+ // 'service' can now be used to invoke operations.
209
+ ```
210
+
211
+ ### Configuration example
212
+ External configuration:
213
+ ```
214
+ export EXAMPLE_SERVICE_AUTH_TYPE=iam
215
+ export EXAMPLE_SERVICE_APIKEY=myapikey
216
+ ```
217
+ Application code:
218
+ ```js
219
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
220
+
221
+ const options = {
222
+ serviceName: 'example_service',
223
+ };
224
+
225
+ const service = ExampleServiceV1.newInstance(options);
226
+
227
+ // 'service' can now be used to invoke operations.
228
+ ```
229
+
230
+
231
+ ## Container Authentication
232
+ The `ContainerAuthenticator` is intended to be used by application code
233
+ running inside a compute resource managed by the IBM Kubernetes Service (IKS)
234
+ in which a secure compute resource token (CR token) has been stored in a file
235
+ within the compute resource's local file system.
236
+ The CR token is similar to an IAM apikey except that it is managed automatically by
237
+ the compute resource provider (IKS).
238
+ This allows the application developer to:
239
+ - avoid storing credentials in application code, configuraton files or a password vault
240
+ - avoid managing or rotating credentials
241
+
242
+ The `ContainerAuthenticator` will retrieve the CR token from
243
+ the compute resource in which the application is running, and will then perform
244
+ the necessary interactions with the IAM token service to obtain an IAM access token
245
+ using the IAM "get token" operation with grant-type `cr-token`.
246
+ The authenticator will repeat these steps to obtain a new IAM access token when the
247
+ current access token expires.
248
+ The IAM access token is added to each outbound request in the `Authorization` header in the form:
249
+ ```
250
+ Authorization: Bearer <IAM-access-token>
251
+ ```
252
+
253
+ ### Properties
254
+
255
+ - crTokenFilename: (optional) the name of the file containing the injected CR token value.
256
+ If not specified, then the authenticator will first try `/var/run/secrets/tokens/vault-token`
257
+ and then `/var/run/secrets/tokens/sa-token` as the default value (first file found is used).
258
+ The application must have `read` permissions on the file containing the CR token value.
259
+
260
+ - iamProfileName: (optional) the name of the linked trusted IAM profile to be used when obtaining the
261
+ IAM access token (a CR token might map to multiple IAM profiles).
262
+ One of `iamProfileName` or `iamProfileId` must be specified.
263
+
264
+ - iamProfileId: (optional) the id of the linked trusted IAM profile to be used when obtaining the
265
+ IAM access token (a CR token might map to multiple IAM profiles).
266
+ One of `iamProfileName` or `iamProfileId` must be specified.
267
+
268
+ - url: (optional) The base endpoint URL of the IAM token service.
269
+ The default value of this property is the "prod" IAM token service endpoint
270
+ (`https://iam.cloud.ibm.com`).
271
+ Make sure that you use an IAM token service endpoint that is appropriate for the
272
+ location of the service being used by your application.
273
+ For example, if you are using an instance of a service in the "production" environment
274
+ (e.g. `https://resource-controller.cloud.ibm.com`),
275
+ then the default "prod" IAM token service endpoint should suffice.
276
+ However, if your application is using an instance of a service in the "staging" environment
277
+ (e.g. `https://resource-controller.test.cloud.ibm.com`),
278
+ then you would also need to configure the authenticator to use the IAM token service "staging"
279
+ endpoint as well (`https://iam.test.cloud.ibm.com`).
280
+
281
+ - clientId/clientSecret: (optional) The `clientId` and `clientSecret` fields are used to form a
282
+ "basic auth" Authorization header for interactions with the IAM token service. If neither field
283
+ is specified, then no Authorization header will be sent with token server requests. These fields
284
+ are optional, but must be specified together.
285
+
286
+ - scope: (optional) the scope to be associated with the IAM access token.
287
+ If not specified, then no scope will be associated with the access token.
288
+
289
+ - disableSslVerification: (optional) A flag that indicates whether verificaton of the server's SSL
290
+ certificate should be disabled or not. The default value is `false`.
291
+
292
+ - headers: (optional) A set of key/value pairs that will be sent as HTTP headers in requests
293
+ made to the IAM token service.
294
+
295
+ - crTokenFilename: (optional) The name of the file containing the injected CR token value.
296
+ If not specified, then `/var/run/secrets/tokens/vault-token` is used as the default value.
297
+ The application must have `read` permissions on the file containing the CR token value.
298
+
299
+ ### Programming example
300
+ ```js
301
+ const { ContainerAuthenticator } = require('ibm-cloud-sdk-core');
302
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
303
+
304
+ const authenticator = new ContainerAuthenticator({
305
+ iamProfileName: 'iam-user123',
306
+ });
307
+
308
+ const options = {
309
+ authenticator,
310
+ };
311
+
312
+ const service = new ExampleServiceV1(options);
313
+
314
+ // 'service' can now be used to invoke operations.
315
+ ```
316
+
317
+ ### Configuration example
318
+ External configuration:
319
+ ```
320
+ export EXAMPLE_SERVICE_AUTH_TYPE=container
321
+ export EXAMPLE_SERVICE_IAM_PROFILE_NAME=iam-user123
322
+ ```
323
+ Application code:
324
+ ```js
325
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
326
+
327
+ const options = {
328
+ serviceName: 'example_service',
329
+ };
330
+
331
+ const service = ExampleServiceV1.newInstance(options);
332
+
333
+ // 'service' can now be used to invoke operations.
334
+ ```
335
+
336
+
337
+ ## VPC Instance Authentication
338
+ The `VpcInstanceAuthenticator` is intended to be used by application code
339
+ running inside a VPC-managed compute resource (virtual server instance) that has been configured
340
+ to use the "compute resource identity" feature.
341
+ The compute resource identity feature allows you to assign a trusted IAM profile to the compute resource as its "identity".
342
+ This, in turn, allows applications running within the compute resource to take on this identity when interacting with
343
+ IAM-secured IBM Cloud services.
344
+ This results in a simplified security model that allows the application developer to:
345
+ - avoid storing credentials in application code, configuraton files or a password vault
346
+ - avoid managing or rotating credentials
347
+
348
+ The `VpcInstanceAuthenticator` will invoke the appropriate operations on the compute resource's locally-available
349
+ VPC Instance Metadata Service to (1) retrieve an instance identity token
350
+ and then (2) exchange that instance identity token for an IAM access token.
351
+ The authenticator will repeat these steps to obtain a new IAM access token whenever the current access token expires.
352
+ The IAM access token is added to each outbound request in the `Authorization` header in the form:
353
+ ```
354
+ Authorization: Bearer <IAM-access-token>
355
+ ```
356
+
357
+ ### Properties
358
+
359
+ - iamProfileCrn: (optional) the crn of the linked trusted IAM profile to be used when obtaining the IAM access token.
360
+
361
+ - iamProfileId: (optional) the id of the linked trusted IAM profile to be used when obtaining the IAM access token.
362
+
363
+ - url: (optional) The VPC Instance Metadata Service's base URL.
364
+ The default value of this property is `http://169.254.169.254`. However, if the VPC Instance Metadata Service is configured
365
+ with the HTTP Secure Protocol setting (`https`), then you should configure this property to be `https://api.metadata.cloud.ibm.com`.
366
+
367
+ Usage Notes:
368
+ 1. At most one of `iamProfileCrn` or `iamProfileId` may be specified. The specified value must map
369
+ to a trusted IAM profile that has been linked to the compute resource (virtual server instance).
370
+
371
+ 2. If both `iamProfileCrn` and `iamProfileId` are specified, then an error occurs.
372
+
373
+ 3. If neither `iamProfileCrn` nor `iamProfileId` are specified, then the default trusted profile linked to the
374
+ compute resource will be used to perform the IAM token exchange.
375
+ If no default trusted profile is defined for the compute resource, then an error occurs.
376
+
377
+
378
+ ### Programming example
379
+ ```js
380
+ const { VpcInstanceAuthenticator } = require('ibm-cloud-sdk-core');
381
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
382
+
383
+ const authenticator = new VpcInstanceAuthenticator({
384
+ iamProfileCrn: 'crn:iam-profile-123',
385
+ });
386
+
387
+ const options = {
388
+ authenticator,
389
+ };
390
+
391
+ const service = new ExampleServiceV1(options);
392
+
393
+ // 'service' can now be used to invoke operations.
394
+ ```
395
+
396
+ ### Configuration example
397
+ External configuration:
398
+ ```
399
+ export EXAMPLE_SERVICE_AUTH_TYPE=vpc
400
+ export EXAMPLE_SERVICE_IAM_PROFILE_CRN=crn:iam-profile-123
401
+ ```
402
+ Application code:
403
+ ```js
404
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
405
+
406
+ const options = {
407
+ serviceName: 'example_service',
408
+ };
409
+
410
+ const service = ExampleServiceV1.newInstance(options);
411
+
412
+ // 'service' can now be used to invoke operations.
413
+ ```
414
+
415
+
416
+ ## Cloud Pak for Data Authentication
417
+ The `CloudPakForDataAuthenticator` will accept a user-supplied username value, along with either a
418
+ password or apikey, and will
419
+ perform the necessary interactions with the Cloud Pak for Data token service to obtain a suitable
420
+ bearer token. The authenticator will also obtain a new bearer token when the current token expires.
421
+ The bearer token is then added to each outbound request in the `Authorization` header in the
422
+ form:
423
+ ```
424
+ Authorization: Bearer <bearer-token>
425
+ ```
426
+ ### Properties
427
+
428
+ - username: (required) the username used to obtain a bearer token.
429
+
430
+ - password: (required if apikey is not specified) the user's password used to obtain a bearer token.
431
+ Exactly one of password or apikey should be specified.
432
+
433
+ - apikey: (required if password is not specified) the user's apikey used to obtain a bearer token.
434
+ Exactly one of password or apikey should be specified.
435
+
436
+ - url: (required) The URL representing the Cloud Pak for Data token service endpoint's base URL string.
437
+ This value should not include the `/v1/authorize` path portion.
438
+
439
+ - disableSslVerification: (optional) A flag that indicates whether verificaton of the server's SSL
440
+ certificate should be disabled or not. The default value is `false`.
441
+
442
+ - headers: (optional) A set of key/value pairs that will be sent as HTTP headers in requests
443
+ made to the Cloud Pak for Data token service.
444
+
445
+ ### Programming examples
446
+ ```js
447
+ const { CloudPakForDataAuthenticator } = require('ibm-cloud-sdk-core');
448
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
449
+
450
+ const authenticator = new CloudPakForDataAuthenticator({
451
+ username: 'myuser',
452
+ apikey: 'myapikey',
453
+ url: 'https://mycp4dhost.com',
454
+ });
455
+
456
+ const options = {
457
+ authenticator,
458
+ };
459
+
460
+ const service = new ExampleServiceV1(options);
461
+
462
+ // 'service' can now be used to invoke operations.
463
+ ```
464
+
465
+ ### Configuration example
466
+ External configuration:
467
+ ```
468
+ # Configure "example_service" with username/apikey.
469
+ export EXAMPLE_SERVICE_AUTH_TYPE=cp4d
470
+ export EXAMPLE_SERVICE_USERNAME=myuser
471
+ export EXAMPLE_SERVICE_APIKEY=myapikey
472
+ export EXAMPLE_SERVICE_URL=https://mycp4dhost.com
473
+ ```
474
+ Application code:
475
+ ```js
476
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
477
+
478
+ const options = {
479
+ serviceName: 'example_service',
480
+ };
481
+
482
+ const service = ExampleServiceV1.newInstance(options);
483
+
484
+ // 'service' can now be used to invoke operations.
485
+ ```
486
+
487
+
488
+ ## Multi-Cloud Saas Platform (MCSP) Authentication
489
+ The `McspAuthenticator` can be used in scenarios where an application needs to
490
+ interact with an IBM Cloud service that has been deployed to a non-IBM Cloud environment (e.g. AWS).
491
+ It accepts a user-supplied apikey and performs the necessary interactions with the
492
+ Multi-Cloud Saas Platform token service to obtain a suitable MCSP access token (a bearer token)
493
+ for the specified apikey.
494
+ The authenticator will also obtain a new bearer token when the current token expires.
495
+ The bearer token is then added to each outbound request in the `Authorization` header in the
496
+ form:
497
+ ```
498
+ Authorization: Bearer <bearer-token>
499
+ ```
500
+
501
+ ### Properties
502
+
503
+ - apikey: (required) the apikey to be used to obtain an MCSP access token.
504
+
505
+ - url: (required) The URL representing the MCSP token service endpoint's base URL string. Do not include the
506
+ operation path (e.g. `/siusermgr/api/1.0/apikeys/token`) as part of this property's value.
507
+
508
+ - disableSSLVerification: (optional) A flag that indicates whether verificaton of the server's SSL
509
+ certificate should be disabled or not. The default value is `false`.
510
+
511
+ - headers: (optional) A set of key/value pairs that will be sent as HTTP headers in requests
512
+ made to the MCSP token service.
513
+
514
+ ### Usage Notes
515
+ - When constructing an McspAuthenticator instance, you must specify the apikey and url properties.
516
+
517
+ - The authenticator will use the token server's `POST /siusermgr/api/1.0/apikeys/token` operation to
518
+ exchange the user-supplied apikey for an MCSP access token (the bearer token).
519
+
520
+ ### Programming example
521
+ ```js
522
+ const { McspAuthenticator } = require('ibm-cloud-sdk-core');
523
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
524
+
525
+ const authenticator = new McspAuthenticator({
526
+ apikey: 'myapikey',
527
+ url: 'https://example.mcsp.token-exchange.com',
528
+ });
529
+
530
+ const options = {
531
+ authenticator,
532
+ };
533
+
534
+ const service = new ExampleServiceV1(options);
535
+
536
+ // 'service' can now be used to invoke operations.
537
+ ```
538
+
539
+ ### Configuration example
540
+ External configuration:
541
+ ```
542
+ export EXAMPLE_SERVICE_AUTH_TYPE=mcsp
543
+ export EXAMPLE_SERVICE_APIKEY=myapikey
544
+ export EXAMPLE_SERVICE_AUTH_URL=https://example.mcsp.token-exchange.com
545
+ ```
546
+ Application code:
547
+ ```js
548
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
549
+
550
+ const options = {
551
+ serviceName: 'example_service',
552
+ };
553
+
554
+ const service = ExampleServiceV1.newInstance(options);
555
+
556
+ // 'service' can now be used to invoke operations.
557
+ ```
558
+
559
+
560
+ ## No Auth Authentication
561
+ The `NoAuthAuthenticator` is a placeholder authenticator which performs no actual authentication function.
562
+ It can be used in situations where authentication needs to be bypassed, perhaps while developing
563
+ or debugging an application or service.
564
+
565
+ ### Properties
566
+ None
567
+
568
+ ### Programming example
569
+ ```js
570
+ const { NoAuthAuthenticator } = require('ibm-cloud-sdk-core');
571
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
572
+
573
+ const authenticator = new NoAuthAuthenticator();
574
+
575
+ const options = {
576
+ authenticator,
577
+ };
578
+
579
+ const service = new ExampleServiceV1(options);
580
+
581
+ // 'service' can now be used to invoke operations.
582
+ ```
583
+
584
+ ### Configuration example
585
+ External configuration:
586
+ ```
587
+ export EXAMPLE_SERVICE_AUTH_TYPE=noauth
588
+ ```
589
+ Application code:
590
+ ```js
591
+ const ExampleServiceV1 = require('<sdk-package-name>/example-service/v1');
592
+
593
+ const options = {
594
+ serviceName: 'example_service',
595
+ };
596
+
597
+ const service = ExampleServiceV1.newInstance(options);
598
+
599
+ // 'service' can now be used to invoke operations.
600
+ ```