{"record":{"id":"7ccc838703212c86","repo":"Kong/insomnia","slug":"unknown-auth-type-authobj-type","errorCode":null,"errorMessage":"unknown auth type: ${authObj.type}","messagePattern":"unknown auth type: (.+?)","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/insomnia-scripting-environment/src/objects/auth.ts","lineNumber":592,"sourceCode":"    }\n    case 'asap': {\n      return {\n        type: 'asap',\n        disabled: findValueInKvArray('disabled', authObj.asap) === 'true',\n        issuer: findValueInKvArray('iss', authObj.asap),\n        subject: findValueInKvArray('sub', authObj.asap),\n        audience: findValueInKvArray('aud', authObj.asap),\n        additionalClaims: findValueInKvArray('claims', authObj.asap),\n        keyId: findValueInKvArray('kid', authObj.asap),\n        privateKey: findValueInKvArray('privateKey', authObj.asap),\n      };\n    }\n    case 'netrc': {\n      // TODO(george): support this in the script side\n      throw new Error('netrc is not supported yet');\n    }\n    default: {\n      throw new Error(`unknown auth type: ${authObj.type}`);\n    }\n  }\n}\n\nexport function toPreRequestAuth(auth: RequestAuthentication | {}): AuthOptions {\n  if (!auth || !('type' in auth) || !auth.type) {\n    return { type: 'noauth' };\n  }\n\n  switch (auth.type) {\n    case 'none': {\n      return { type: 'noauth' };\n    }\n    case 'apikey': {\n      return {\n        type: 'apikey',\n        apikey: [\n          { key: 'disabled', value: auth.disabled ? 'true' : 'false' },","sourceCodeStart":574,"sourceCodeEnd":610,"githubUrl":"https://github.com/Kong/insomnia/blob/d9bb2b0142600f21309832daea3317942d285984/packages/insomnia-scripting-environment/src/objects/auth.ts#L574-L610","documentation":"Error \"unknown auth type: ${authObj.type}\" thrown in Kong/insomnia.","triggerScenarios":"Thrown at packages/insomnia-scripting-environment/src/objects/auth.ts:592 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"d9bb2b0142600f21309832daea3317942d285984","analyzedAt":"2026-08-26T18:04:05.187Z","schemaVersion":2},"datasetVersion":"2026-08-26T21:11:00.512Z"}