Skip to main content

@atamaco/fetcher-atama

The "Atama Fetcher" is fetching experience information from the Delivery API. See fetcher to understand how to use the getAllPaths and getData methods. Below you'll find out how to configure the Atama Fetcher via its constructor.

Installation

npm i @atamaco/fetcher-atama

Usage

import { FetcherAtama } from '@atamaco/fetcher-atama';

const client = new FetcherAtama({
apiKey: "<CONTENT_DELIVERY_API_KEY>";
workspaceId: "<WORKSPACE_ID>";
});

API

FetcherAtama(config, logger)

ParameterTypeDefaultRequired?Description
config.apiKeystring-YesAn API Key for the Delivery API
config.workspaceIdstring-YesThe id of the workspace you used to publish experiences.
config.environmentpreview or prodprodNoWhether you want to use the "preview" or "production" environment
config.urlstringhttps://cdn.atama.appNoAn alternative URL to use for the Delivery API.
loggerLogger-NoA logger object to hook into the AtamaClient logs. See Logger