intercom-client
Version:
Official Node bindings to the Intercom API
65 lines (64 loc) • 2.38 kB
TypeScript
import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js";
import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.js";
import * as core from "../../../../core/index.js";
import * as Intercom from "../../../index.js";
export declare namespace NotesClient {
interface Options extends BaseClientOptions {
}
interface RequestOptions extends BaseRequestOptions {
}
}
/**
* Everything about your Notes
*/
export declare class NotesClient {
protected readonly _options: NormalizedClientOptionsWithAuth<NotesClient.Options>;
constructor(options?: NotesClient.Options);
/**
* You can fetch a list of notes that are associated to a contact.
*
* @param {Intercom.ListContactNotesRequest} request
* @param {NotesClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Intercom.NotFoundError}
*
* @example
* await client.notes.list({
* contact_id: "contact_id"
* })
*/
list(request: Intercom.ListContactNotesRequest, requestOptions?: NotesClient.RequestOptions): Promise<core.Page<Intercom.Note, Intercom.NoteList>>;
/**
* You can add a note to a single contact.
*
* @param {Intercom.CreateContactNoteRequest} request
* @param {NotesClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Intercom.NotFoundError}
*
* @example
* await client.notes.create({
* contact_id: "123",
* body: "Hello",
* admin_id: "123"
* })
*/
create(request: Intercom.CreateContactNoteRequest, requestOptions?: NotesClient.RequestOptions): core.HttpResponsePromise<Intercom.Note>;
private __create;
/**
* You can fetch the details of a single note.
*
* @param {Intercom.FindNoteRequest} request
* @param {NotesClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Intercom.UnauthorizedError}
* @throws {@link Intercom.NotFoundError}
*
* @example
* await client.notes.find({
* note_id: 1
* })
*/
find(request: Intercom.FindNoteRequest, requestOptions?: NotesClient.RequestOptions): core.HttpResponsePromise<Intercom.Note>;
private __find;
}