Database utility for using FaunaDB with the TripleCheck broker. It implements the repository base at triplecheck-core.
triplecheck-broker
.Security
, create a key for the database and set the role to Server
.env
file like this: FAUNA_KEY=some-secret-random-key
triplecheck
)Key
and set the term to data.key
; also enable Serialized
and Unique
FAUNA_KEY
(as per above), so use something like dotenv to simplify getting that valueimport { TripleCheckBroker } from 'triplecheck-broker';
import { FaunaRepository } from 'triplecheck-repository-fauna';
import dotenv from 'dotenv';
dotenv.config();
const repository = FaunaRepository();
const request = "Get this from your API request and transform it as needed";
const payload = "Body";
const { responseData, status, headers } = await TripleCheckBroker(request, payload, repository);
Generated using TypeDoc