Contexte géant
Base de connaissancesDéveloppeurs
Le Sign Up Now

CRM

Manage contacts, companies, activities, and CRM data.


GET

Get activity

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/activities/{activityId}

Returns a single CRM activity by ID. Each activity is a natural-language description of something that happened, tagged by source app with optional JSON metadata and linked contact/company objects.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
activityIdRequired
path · string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: activity } = await gc.crm.getCrmActivity({  organizationId: "org_123",  projectId: "proj_123",  appId: "app_123",  activityId: "act_123"});
GET

Get activities

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/activities

Returns a paginated timeline of CRM activities for the specified app, newest first. Each activity is a natural-language description of something that happened for a contact (or company), tagged by source app and optionally enriched with a JSON `data` payload. Supports free-text search across the description.

Parameters
page
query · number
pageSize
query · number
search
query · string
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: activities } = await gc.crm.getCrmActivitiesList({  organizationId: "org_123",  projectId: "proj_123",  appId: "app_123"});
POST

Log activity

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/activities

Appends an activity to the CRM timeline. `description` is a natural-language sentence ('Viewed pricing page', 'Unsubscribed from newsletter'). `source` identifies which app wrote it. Optional `data` carries structured metadata for agents to read. Link to a contact and/or company via id.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
BodyRequired
data
object
source
string
companyId
string
contactId
string
descriptionRequired
string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const orgId = "org_123";const projectId = "proj_123";const appId = "app_123";const activityData = { type: "call", notes: "Follow-up discussion" };
const { data: activity } = await gc.crm.logCrmActivity({  organizationId: orgId,  projectId,  appId,  data: activityData});
GET

Get activities for a company

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/companies/{companyId}/activities

Returns the natural-language activity timeline for a company, newest first. Each row is a description of something that happened, tagged by source app with optional JSON metadata.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
companyIdRequired
path · string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: activities } = await gc.crm.getCrmCompanyActivities({  organizationId: "org_123",  projectId: "proj_123",  appId: "app_123",  companyId: "comp_123"});
GET

Get contacts for a company

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/companies/{companyId}/contacts

Returns all CRM contacts linked to a specific company, ordered by last name then first name. Each contact includes name, email, phone, title, department, status, source, tags, and linked company object.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
companyIdRequired
path · string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const organizationId = "org_123";const projectId = "proj_123";const appId = "app_123";const companyId = "comp_123";
const { data: contacts } = await gc.crm.getCrmCompanyContacts({  organizationId,  projectId,  appId,  companyId});
GET

Get company

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/companies/{companyId}

Returns a single CRM company by ID, including name, website, industry, size, annual revenue, contact info, address, tags, custom properties, and a count of associated contacts.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
companyIdRequired
path · string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: company } = await gc.crm.getCrmCompany({  organizationId: "YOUR_ORGANIZATION_ID",  projectId: "YOUR_PROJECT_ID",  appId: "YOUR_APP_ID",  companyId: "YOUR_COMPANY_ID"});
GET

Get companies

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/companies

Returns a paginated list of all CRM companies for the specified app. Supports search by company name or industry. Each company includes a count of associated contacts.

Parameters
page
query · number
pageSize
query · number
search
query · string
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const org = "org_123";const project = "proj_123";const app = "app_123";
const { data: companies } = await gc.crm.getCrmCompaniesList({  organizationId: org,  projectId: project,  appId: app});
GET

Get activities for a contact

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/contacts/{contactId}/activities

Returns the natural-language activity timeline for a contact, newest first. Each row is a description of something that happened, tagged by source app with optional JSON metadata.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
contactIdRequired
path · string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: activities } = await gc.crm.getCrmContactActivities({  organizationId: "YOUR_ORGANIZATION_ID",  projectId: "YOUR_PROJECT_ID",  appId: "YOUR_APP_ID",  contactId: "YOUR_CONTACT_ID"});
PUT

Set contact field

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/contacts/{contactId}/fields

Sets a single key on a contact's custom `properties`. Merges at the key level — siblings are preserved. Use this instead of PUT /contacts when only one field needs to change, especially from other apps.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
contactIdRequired
path · string
BodyRequired
keyRequired
string
valueRequired
any
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const orgId = "org_123";const projectId = "proj_123";const appId = "app_123";const contactId = "contact_123";const fieldData = { role: "admin" };
const { data: result } = await gc.crm.setCrmContactField({  organizationId: orgId,  projectId,  appId,  contactId,  data: fieldData});
GET

Get contact

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/contacts/{contactId}

Returns a single CRM contact by ID, including linked company details. Fields include name, email, phone, title, department, status, source, tags, email subscription status, and last activity timestamp.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
contactIdRequired
path · string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: contact } = await gc.crm.getCrmContact({  organizationId: "org_123",  projectId: "proj_123",  appId: "app_123",  contactId: "contact_123"});
PUT

Update contact

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/contacts/{contactId}

Updates a CRM contact. All fields are optional — only provided fields are updated. Returns 409 if email or phone conflicts with an existing contact.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
contactIdRequired
path · string
BodyRequired
tags
array
email
string
phone
string
title
string
locale
union
source
union
status
union
lastName
string
companyId
string
firstName
string
department
string
properties
object
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: contact } = await gc.crm.updateCrmContact({  organizationId: "org_123",  projectId: "proj_123",  appId: "app_123",  contactId: "contact_123",  data: { email: "user@example.com" }});
POST

Tag contact

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/contacts/{contactId}/tags

Adds a tag to a contact. Tags are free-form strings used for segmenting, gating marketing messages, and ad-hoc grouping. Idempotent — adding an existing tag is a no-op.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
contactIdRequired
path · string
BodyRequired
tagRequired
string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const organizationId = "org_123";const projectId = "proj_123";const appId = "app_123";const contactId = "contact_123";const data = { tags: ["premium"] };
const { data: taggedContact } = await gc.crm.tagCrmContact({  organizationId,  projectId,  appId,  contactId,  data});
DELETE

Untag contact

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/contacts/{contactId}/tags

Removes a tag from a contact. Idempotent — removing a tag the contact doesn't have is a no-op.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
contactIdRequired
path · string
BodyRequired
tagRequired
string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const orgId = "org_123";const projectId = "proj_123";const appId = "app_123";const contactId = "contact_123";const data = { tag: "example-tag" };
const result = await gc.crm.untagCrmContact(orgId, projectId, appId, contactId, data);
GET

Get contacts

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/contacts

Returns a paginated list of all CRM contacts for the specified app. Supports search by first name, last name, or email. Each contact includes associated company info if linked.

Parameters
page
query · number
pageSize
query · number
search
query · string
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const { data: contacts } = await gc.crm.getCrmContactsList({  organizationId: "org_1",  projectId: "proj_1",  appId: "app_1"});
POST

Create contact

/organizations/{organizationId}/projects/{projectId}/apps/crm/{appId}/contacts

Creates a new CRM contact. Requires firstName and lastName. Optionally link to a company via companyId. Supports email, phone, title, department, status, source, custom properties, and tags.

Parameters
organizationIdRequired
path · string
projectIdRequired
path · string
appIdRequired
path · string
BodyRequired
tags
array
email
string
phone
string
title
string
locale
union
source
union
status
union
lastNameRequired
string
companyId
string
firstNameRequired
string
department
string
properties
object
SDK
import { createGiantContext } from "@giantcontext/sdk-typescript";
const gc = createGiantContext({ apiKey: process.env.GIANTCONTEXT_API_KEY! });
const orgId = "org_123";const projectId = "proj_123";const appId = "app_123";const data = { email: "test@example.com", name: "Test User" };
const { data: contact } = await gc.crm.createCrmContact({  organizationId: orgId,  projectId,  appId,  data});

Built byHuman
This content was designed and written by a human.
[0]
Colonne
    Colonne 2
    • Discord
    • BlueSky

    © 2026 Giant Context
    ConfidentialitéConditions d'utilisationPolitique relative aux cookies
    CRM