typescript
import { ObjectiveAI, Functions } from "objectiveai";
const client = new ObjectiveAI({
apiKey: process.env.OBJECTIVEAI_API_KEY,
});
// Browse available functions
const functions = await Functions.list(client);
console.log(functions.data);
// Execute a function with a profile
// const result = await Functions.Executions.create(
// client,
// { owner: "fn-owner", repository: "fn-repo" },
// { owner: "profile-owner", repository: "profile-repo" },
// { input: { text: "Hello world" }, from_cache: true, from_rng: true }
// );
// console.log(result.output);