{"version":3,"file":"resolveCredentials.mjs","sources":["../../../../../../src/inAppMessaging/providers/pinpoint/utils/resolveCredentials.ts"],"sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { fetchAuthSession } from '@aws-amplify/core';\nimport { InAppMessagingValidationErrorCode, assertValidationError, } from '../../../errors';\n/**\n * @internal\n */\nexport const resolveCredentials = async () => {\n    const { credentials, identityId } = await fetchAuthSession();\n    assertValidationError(!!credentials, InAppMessagingValidationErrorCode.NoCredentials);\n    return { credentials, identityId };\n};\n"],"names":[],"mappings":";;;;;AAAA;AACA;AAGA;AACA;AACA;AACY,MAAC,kBAAkB,GAAG,YAAY;AAC9C,IAAI,MAAM,EAAE,WAAW,EAAE,UAAU,EAAE,GAAG,MAAM,gBAAgB,EAAE;AAChE,IAAI,qBAAqB,CAAC,CAAC,CAAC,WAAW,EAAE,iCAAiC,CAAC,aAAa,CAAC;AACzF,IAAI,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE;AACtC;;;;"}