Profiles API
Create audience profiles with Noketa
Use client.profiles.create to create a profile in a target list.
Method Signature
client.profiles.create(payload: CreateProfileRequest): Promise<CreateProfileResponse>Request Shape
type CreateProfileRequest = {
listId: string;
email: string;
attributes: ProfileAttributes;
};Example
import { Noketa } from "noketa";
const client = new Noketa(process.env.NOKETA_API_KEY!);
const response = await client.profiles.create({
listId: "list_123",
email: "person@example.com",
attributes: {
first_name: "Jane",
last_name: "Doe",
locale: "en",
external_id: "usr_123",
properties: {
plan: "pro",
signup_source: "landing_page",
},
},
});Notes
attributessupports both standard fields and custom keys.- Dates such as
birthdateandlast_event_dateshould be passed asDateobjects.