Skip to main content

AtlassianRestClientWrapper

@appfire/fuse-auth-coreDocs


@appfire/fuse-auth-core / AtlassianRestClientWrapper

Class: AtlassianRestClientWrapper

Represents a wrapper for the AtlassianRestClient that handles instance creation and authentication.

Constructors

new AtlassianRestClientWrapper()

new AtlassianRestClientWrapper(): AtlassianRestClientWrapper

Returns

AtlassianRestClientWrapper

Methods

getInstance()

static getInstance(_event): Promise\<[AtlassianRestClient, string]>

Retrieves an instance of AtlassianRestClient and the user ID based on the provided event. If uses App data in Authorizer Context otherwise makes call to db for the same.

Parameters

_event: AuthAPIGatewayEvent

The AuthAPIGatewayEvent object representing the API Gateway event.

Returns

Promise\<[AtlassianRestClient, string]>

A Promise that resolves to an array containing the AtlassianRestClient instance and the user ID.

Throws

Throws an error if the authorization information is missing.

Defined in

products/atlassian/atlassian.restclient.wrapper.ts:38