@graph8/sdk 0.251.0 → 0.260.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -2
- package/dist/cli.js +216 -0
- package/dist/index.d.mts +104 -7
- package/dist/index.d.ts +104 -7
- package/dist/index.js +44 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +44 -3
- package/dist/index.mjs.map +1 -1
- package/dist/react.d.mts +102 -7
- package/dist/react.d.ts +102 -7
- package/dist/react.js +62 -11
- package/dist/react.js.map +1 -1
- package/dist/react.mjs +53 -12
- package/dist/react.mjs.map +1 -1
- package/dist/types/README.md +7 -0
- package/dist/types/agency.d.ts +20 -0
- package/dist/types/agentSetup.d.ts +57 -0
- package/dist/types/api.d.ts +127 -0
- package/dist/types/appClient.d.ts +99 -0
- package/dist/types/appPlatform.d.ts +269 -0
- package/dist/types/appTokens.d.ts +125 -0
- package/dist/types/apps.d.ts +130 -0
- package/dist/types/audiences.d.ts +88 -0
- package/dist/types/calendar.d.ts +55 -0
- package/dist/types/campaigns.d.ts +61 -0
- package/dist/types/chat.d.ts +35 -0
- package/dist/types/cli.d.ts +14 -0
- package/dist/types/companies.d.ts +123 -0
- package/dist/types/contacts.d.ts +200 -0
- package/dist/types/copilot.d.ts +31 -0
- package/dist/types/core.d.ts +1052 -0
- package/dist/types/deals.d.ts +215 -0
- package/dist/types/enrich.d.ts +51 -0
- package/dist/types/fields.d.ts +84 -0
- package/dist/types/forms.d.ts +16 -0
- package/dist/types/http.d.ts +141 -0
- package/dist/types/inbox.d.ts +123 -0
- package/dist/types/index.d.ts +63 -0
- package/dist/types/intent.d.ts +196 -0
- package/dist/types/lists.d.ts +44 -0
- package/dist/types/mailboxes.d.ts +240 -0
- package/dist/types/marketplace.d.ts +62 -0
- package/dist/types/meetings.d.ts +70 -0
- package/dist/types/newsletter.d.ts +212 -0
- package/dist/types/notes.d.ts +57 -0
- package/dist/types/objects.d.ts +281 -0
- package/dist/types/pipelines.d.ts +135 -0
- package/dist/types/quotes.d.ts +143 -0
- package/dist/types/react.d.ts +978 -0
- package/dist/types/search.d.ts +99 -0
- package/dist/types/sequences.d.ts +255 -0
- package/dist/types/signals.d.ts +28 -0
- package/dist/types/skills.d.ts +176 -0
- package/dist/types/snippet.d.ts +24 -0
- package/dist/types/studio.d.ts +161 -0
- package/dist/types/tasks.d.ts +101 -0
- package/dist/types/types.d.ts +45 -0
- package/dist/types/utils.d.ts +21 -0
- package/dist/types/version.d.ts +10 -0
- package/dist/types/visitors.d.ts +29 -0
- package/dist/types/voice.d.ts +304 -0
- package/dist/types/webhooks.d.ts +71 -0
- package/dist/types/workflows.d.ts +229 -0
- package/docs/agents.md +748 -0
- package/docs/api/README.md +165 -0
- package/docs/api/accounts.d.ts +396 -0
- package/docs/api/accounts.md +644 -0
- package/docs/api/adCampaigns.d.ts +707 -0
- package/docs/api/adCampaigns.md +1091 -0
- package/docs/api/adCreatives.d.ts +996 -0
- package/docs/api/adCreatives.md +1708 -0
- package/docs/api/agency.d.ts +556 -0
- package/docs/api/agency.md +845 -0
- package/docs/api/agent.d.ts +330 -0
- package/docs/api/agent.md +514 -0
- package/docs/api/agents.d.ts +1622 -0
- package/docs/api/agents.md +2860 -0
- package/docs/api/aiInbox.d.ts +1984 -0
- package/docs/api/aiInbox.md +3490 -0
- package/docs/api/analytics.d.ts +1273 -0
- package/docs/api/analytics.md +2095 -0
- package/docs/api/apiKeys.d.ts +252 -0
- package/docs/api/apiKeys.md +318 -0
- package/docs/api/appDeployments.d.ts +236 -0
- package/docs/api/appDeployments.md +471 -0
- package/docs/api/appDomains.d.ts +171 -0
- package/docs/api/appDomains.md +281 -0
- package/docs/api/appLogs.d.ts +120 -0
- package/docs/api/appLogs.md +159 -0
- package/docs/api/appObjects.d.ts +415 -0
- package/docs/api/appObjects.md +568 -0
- package/docs/api/appPages.d.ts +557 -0
- package/docs/api/appPages.md +796 -0
- package/docs/api/appPlatformTokens.d.ts +123 -0
- package/docs/api/appPlatformTokens.md +172 -0
- package/docs/api/appointments.d.ts +2361 -0
- package/docs/api/appointments.md +3917 -0
- package/docs/api/apps.d.ts +822 -0
- package/docs/api/apps.md +1342 -0
- package/docs/api/assertUpsert.d.ts +286 -0
- package/docs/api/assertUpsert.md +370 -0
- package/docs/api/audienceSyncs.d.ts +259 -0
- package/docs/api/audienceSyncs.md +395 -0
- package/docs/api/brandKit.d.ts +686 -0
- package/docs/api/brandKit.md +1133 -0
- package/docs/api/bugReports.d.ts +181 -0
- package/docs/api/bugReports.md +268 -0
- package/docs/api/by-path.md +3260 -0
- package/docs/api/calendarInvites.d.ts +117 -0
- package/docs/api/calendarInvites.md +148 -0
- package/docs/api/campaignWorkflows.d.ts +152 -0
- package/docs/api/campaignWorkflows.md +200 -0
- package/docs/api/campaigns.d.ts +721 -0
- package/docs/api/campaigns.md +1236 -0
- package/docs/api/channels.d.ts +171 -0
- package/docs/api/channels.md +235 -0
- package/docs/api/cliCampaigns.d.ts +205 -0
- package/docs/api/cliCampaigns.md +256 -0
- package/docs/api/cliPipelines.d.ts +324 -0
- package/docs/api/cliPipelines.md +562 -0
- package/docs/api/clickHouse.d.ts +115 -0
- package/docs/api/clickHouse.md +138 -0
- package/docs/api/companies.d.ts +1636 -0
- package/docs/api/companies.md +2211 -0
- package/docs/api/companyIntelligence.d.ts +299 -0
- package/docs/api/companyIntelligence.md +488 -0
- package/docs/api/contacts.d.ts +2173 -0
- package/docs/api/contacts.md +3143 -0
- package/docs/api/content.d.ts +968 -0
- package/docs/api/content.md +1667 -0
- package/docs/api/contentGridSkills.d.ts +177 -0
- package/docs/api/contentGridSkills.md +271 -0
- package/docs/api/copilot.d.ts +1017 -0
- package/docs/api/copilot.md +1765 -0
- package/docs/api/crmSyncs.d.ts +215 -0
- package/docs/api/crmSyncs.md +301 -0
- package/docs/api/customerSuccess.d.ts +491 -0
- package/docs/api/customerSuccess.md +776 -0
- package/docs/api/deals.d.ts +1696 -0
- package/docs/api/deals.md +2432 -0
- package/docs/api/deliverability.d.ts +418 -0
- package/docs/api/deliverability.md +677 -0
- package/docs/api/desk.d.ts +1765 -0
- package/docs/api/desk.md +3007 -0
- package/docs/api/dialer.d.ts +1185 -0
- package/docs/api/dialer.md +2166 -0
- package/docs/api/dialerAnalytics.d.ts +187 -0
- package/docs/api/dialerAnalytics.md +257 -0
- package/docs/api/documents.d.ts +895 -0
- package/docs/api/documents.md +1440 -0
- package/docs/api/duplicates.d.ts +195 -0
- package/docs/api/duplicates.md +315 -0
- package/docs/api/eSign.d.ts +38 -0
- package/docs/api/eSign.md +54 -0
- package/docs/api/eSignature.d.ts +242 -0
- package/docs/api/eSignature.md +341 -0
- package/docs/api/enrichment.d.ts +3207 -0
- package/docs/api/enrichment.md +5225 -0
- package/docs/api/events.d.ts +115 -0
- package/docs/api/events.md +105 -0
- package/docs/api/fields.d.ts +482 -0
- package/docs/api/fields.md +566 -0
- package/docs/api/forms.d.ts +1012 -0
- package/docs/api/forms.md +1542 -0
- package/docs/api/gtmCampaigns.d.ts +662 -0
- package/docs/api/gtmCampaigns.md +1044 -0
- package/docs/api/gtmContext.d.ts +1187 -0
- package/docs/api/gtmContext.md +2112 -0
- package/docs/api/gtmDeliverability.d.ts +60 -0
- package/docs/api/gtmDeliverability.md +63 -0
- package/docs/api/gtmKnowledgeBase.d.ts +76 -0
- package/docs/api/gtmKnowledgeBase.md +91 -0
- package/docs/api/gtmLaunchHelpers.d.ts +123 -0
- package/docs/api/gtmLaunchHelpers.md +148 -0
- package/docs/api/gtmLibrary.d.ts +448 -0
- package/docs/api/gtmLibrary.md +780 -0
- package/docs/api/health.d.ts +39 -0
- package/docs/api/health.md +58 -0
- package/docs/api/imageLibrary.d.ts +341 -0
- package/docs/api/imageLibrary.md +569 -0
- package/docs/api/imports.d.ts +157 -0
- package/docs/api/imports.md +174 -0
- package/docs/api/inbox.d.ts +709 -0
- package/docs/api/inbox.md +1067 -0
- package/docs/api/install.d.ts +213 -0
- package/docs/api/install.md +317 -0
- package/docs/api/installedApps.d.ts +131 -0
- package/docs/api/installedApps.md +241 -0
- package/docs/api/integrationStatus.d.ts +142 -0
- package/docs/api/integrationStatus.md +205 -0
- package/docs/api/integrations.d.ts +2327 -0
- package/docs/api/integrations.md +3791 -0
- package/docs/api/intent.d.ts +482 -0
- package/docs/api/intent.md +858 -0
- package/docs/api/knowledge.d.ts +501 -0
- package/docs/api/knowledge.md +843 -0
- package/docs/api/knowledgeBase.d.ts +84 -0
- package/docs/api/knowledgeBase.md +96 -0
- package/docs/api/landingPages.d.ts +1411 -0
- package/docs/api/landingPages.md +2488 -0
- package/docs/api/leads.d.ts +133 -0
- package/docs/api/leads.md +180 -0
- package/docs/api/library.d.ts +217 -0
- package/docs/api/library.md +338 -0
- package/docs/api/linkedIn.d.ts +227 -0
- package/docs/api/linkedIn.md +289 -0
- package/docs/api/linkedInOutreach.d.ts +727 -0
- package/docs/api/linkedInOutreach.md +990 -0
- package/docs/api/lists.d.ts +1106 -0
- package/docs/api/lists.md +1609 -0
- package/docs/api/logs.d.ts +71 -0
- package/docs/api/logs.md +70 -0
- package/docs/api/mailboxes.d.ts +1050 -0
- package/docs/api/mailboxes.md +1690 -0
- package/docs/api/marketingIntelligence.d.ts +256 -0
- package/docs/api/marketingIntelligence.md +454 -0
- package/docs/api/marketplace.d.ts +3173 -0
- package/docs/api/marketplace.md +5953 -0
- package/docs/api/mcp.d.ts +69 -0
- package/docs/api/mcp.md +69 -0
- package/docs/api/me.d.ts +54 -0
- package/docs/api/me.md +56 -0
- package/docs/api/meetings.d.ts +539 -0
- package/docs/api/meetings.md +747 -0
- package/docs/api/newsletter.d.ts +1613 -0
- package/docs/api/newsletter.md +2746 -0
- package/docs/api/notes.d.ts +517 -0
- package/docs/api/notes.md +888 -0
- package/docs/api/notifications.d.ts +94 -0
- package/docs/api/notifications.md +105 -0
- package/docs/api/objects.d.ts +621 -0
- package/docs/api/objects.md +1098 -0
- package/docs/api/openSearch.d.ts +234 -0
- package/docs/api/openSearch.md +297 -0
- package/docs/api/ops.d.ts +299 -0
- package/docs/api/ops.md +339 -0
- package/docs/api/orgGovernance.d.ts +393 -0
- package/docs/api/orgGovernance.md +623 -0
- package/docs/api/orgVideos.d.ts +184 -0
- package/docs/api/orgVideos.md +252 -0
- package/docs/api/organizationSettings.d.ts +626 -0
- package/docs/api/organizationSettings.md +911 -0
- package/docs/api/phoneNumbers.d.ts +484 -0
- package/docs/api/phoneNumbers.md +777 -0
- package/docs/api/profile.d.ts +329 -0
- package/docs/api/profile.md +540 -0
- package/docs/api/programmaticPages.d.ts +400 -0
- package/docs/api/programmaticPages.md +626 -0
- package/docs/api/providerDomains.d.ts +866 -0
- package/docs/api/providerDomains.md +1446 -0
- package/docs/api/providerUsage.d.ts +129 -0
- package/docs/api/providerUsage.md +186 -0
- package/docs/api/public.d.ts +69 -0
- package/docs/api/public.md +78 -0
- package/docs/api/publicCopilot.d.ts +67 -0
- package/docs/api/publicCopilot.md +80 -0
- package/docs/api/publicSignals.d.ts +66 -0
- package/docs/api/publicSignals.md +71 -0
- package/docs/api/publicVisitors.d.ts +97 -0
- package/docs/api/publicVisitors.md +118 -0
- package/docs/api/quotes.d.ts +1564 -0
- package/docs/api/quotes.md +2553 -0
- package/docs/api/radar.d.ts +808 -0
- package/docs/api/radar.md +1431 -0
- package/docs/api/radarReports.d.ts +208 -0
- package/docs/api/radarReports.md +306 -0
- package/docs/api/recordRoles.d.ts +143 -0
- package/docs/api/recordRoles.md +175 -0
- package/docs/api/repos.d.ts +146 -0
- package/docs/api/repos.md +211 -0
- package/docs/api/research.d.ts +295 -0
- package/docs/api/research.md +534 -0
- package/docs/api/revenue.d.ts +402 -0
- package/docs/api/revenue.md +608 -0
- package/docs/api/revenueAnalytics.d.ts +147 -0
- package/docs/api/revenueAnalytics.md +212 -0
- package/docs/api/revenueLifecycle.d.ts +207 -0
- package/docs/api/revenueLifecycle.md +274 -0
- package/docs/api/revenueRecords.d.ts +372 -0
- package/docs/api/revenueRecords.md +563 -0
- package/docs/api/roles.d.ts +431 -0
- package/docs/api/roles.md +812 -0
- package/docs/api/salesCoach.d.ts +877 -0
- package/docs/api/salesCoach.md +1540 -0
- package/docs/api/sandbox.d.ts +210 -0
- package/docs/api/sandbox.md +380 -0
- package/docs/api/scans.d.ts +104 -0
- package/docs/api/scans.md +136 -0
- package/docs/api/scheduleBuy.d.ts +293 -0
- package/docs/api/scheduleBuy.md +431 -0
- package/docs/api/scraping.d.ts +266 -0
- package/docs/api/scraping.md +383 -0
- package/docs/api/sdrAnalytics.d.ts +138 -0
- package/docs/api/sdrAnalytics.md +246 -0
- package/docs/api/search.d.ts +598 -0
- package/docs/api/search.md +866 -0
- package/docs/api/seo.d.ts +447 -0
- package/docs/api/seo.md +660 -0
- package/docs/api/sequenceLifecycle.d.ts +439 -0
- package/docs/api/sequenceLifecycle.md +513 -0
- package/docs/api/sequences.d.ts +1936 -0
- package/docs/api/sequences.md +3232 -0
- package/docs/api/settings.d.ts +448 -0
- package/docs/api/settings.md +731 -0
- package/docs/api/signals.d.ts +1441 -0
- package/docs/api/signals.md +2526 -0
- package/docs/api/signatures.d.ts +719 -0
- package/docs/api/signatures.md +1247 -0
- package/docs/api/skills.d.ts +230 -0
- package/docs/api/skills.md +466 -0
- package/docs/api/snippet.d.ts +85 -0
- package/docs/api/snippet.md +106 -0
- package/docs/api/socialPublishing.d.ts +824 -0
- package/docs/api/socialPublishing.md +1245 -0
- package/docs/api/studioDocuments.d.ts +244 -0
- package/docs/api/studioDocuments.md +348 -0
- package/docs/api/support.d.ts +90 -0
- package/docs/api/support.md +76 -0
- package/docs/api/suppressions.d.ts +241 -0
- package/docs/api/suppressions.md +343 -0
- package/docs/api/surveys.d.ts +847 -0
- package/docs/api/surveys.md +1223 -0
- package/docs/api/tasks.d.ts +813 -0
- package/docs/api/tasks.md +1344 -0
- package/docs/api/teamMembers.d.ts +668 -0
- package/docs/api/teamMembers.md +1040 -0
- package/docs/api/teams.d.ts +784 -0
- package/docs/api/teams.md +1395 -0
- package/docs/api/usage.d.ts +277 -0
- package/docs/api/usage.md +389 -0
- package/docs/api/visitors.d.ts +690 -0
- package/docs/api/visitors.md +1075 -0
- package/docs/api/voice.d.ts +4661 -0
- package/docs/api/voice.md +7905 -0
- package/docs/api/webAnalytics.d.ts +964 -0
- package/docs/api/webAnalytics.md +1452 -0
- package/docs/api/webChat.d.ts +1704 -0
- package/docs/api/webChat.md +2048 -0
- package/docs/api/webhooks.d.ts +251 -0
- package/docs/api/webhooks.md +386 -0
- package/docs/api/websiteEditor.d.ts +324 -0
- package/docs/api/websiteEditor.md +517 -0
- package/docs/api/work.d.ts +2298 -0
- package/docs/api/work.md +3096 -0
- package/docs/api/workbench.d.ts +2962 -0
- package/docs/api/workbench.md +4884 -0
- package/docs/api/workflows.d.ts +1218 -0
- package/docs/api/workflows.md +2302 -0
- package/docs/sdk-clients.md +4339 -0
- package/package.json +10 -3
|
@@ -0,0 +1,1395 @@
|
|
|
1
|
+
<!-- Generated by sdk/js/scripts/generate-agent-docs.ts from developer-contract/openapi.json. Regenerated on every build. -->
|
|
2
|
+
|
|
3
|
+
# `g8.api.teams`: Teams
|
|
4
|
+
|
|
5
|
+
35 operations (16 read, 8 write, 10 destructive, 1 billable).
|
|
6
|
+
|
|
7
|
+
No hand-written client covers this area. Call it through `g8.api.teams.*` as shown below, or by operationId with `g8.api.call(operationId, input)`.
|
|
8
|
+
|
|
9
|
+
Every example below assumes this setup (server-side, API key):
|
|
10
|
+
|
|
11
|
+
```ts
|
|
12
|
+
import { g8 } from "@graph8/sdk";
|
|
13
|
+
|
|
14
|
+
g8.init({ apiKey: process.env.G8_API_KEY! });
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
Example values are placeholders that match each field's type. Only required fields are shown. Every example is type-checked against the SDK in CI.
|
|
18
|
+
|
|
19
|
+
Exact TypeScript types for every operation on this page, and every schema they use: [teams.d.ts](teams.d.ts).
|
|
20
|
+
|
|
21
|
+
## Operations
|
|
22
|
+
|
|
23
|
+
| Call | HTTP | Tier | Scope | Summary |
|
|
24
|
+
|---|---|---|---|---|
|
|
25
|
+
| [`addTeamAgent`](#op-addteamagent) | `POST /api/v1/teams/{team_id}/agents` | write | `team:write` | Add Team Agent |
|
|
26
|
+
| [`addTeamMember`](#op-addteammember) | `POST /api/v1/teams/{team_id}/members` | write | `team:write` | Add Team Member |
|
|
27
|
+
| [`assignCampaignToTeam`](#op-assigncampaigntoteam) | `POST /api/v1/teams/{team_id}/campaigns` | write | `team:write` | Assign Campaign To Team |
|
|
28
|
+
| [`assignLinkedinAccountToTeam`](#op-assignlinkedinaccounttoteam) | `POST /api/v1/teams/{team_id}/linkedin-accounts` | write | `team:write` | Assign Linkedin Account To Team |
|
|
29
|
+
| [`assignMailboxToTeam`](#op-assignmailboxtoteam) | `POST /api/v1/teams/{team_id}/mailboxes` | write | `team:write` | Assign Mailbox To Team |
|
|
30
|
+
| [`assignPhoneToTeam`](#op-assignphonetoteam) | `POST /api/v1/teams/{team_id}/phone-numbers` | write | `team:write` | Assign Phone To Team |
|
|
31
|
+
| [`autoComposeSuggest`](#op-autocomposesuggest) | `POST /api/v1/teams/auto-compose/suggest` | billable | `team:run` | Auto Compose Suggest |
|
|
32
|
+
| [`createTeam`](#op-createteam) | `POST /api/v1/teams` | write | `team:write` | Create Team |
|
|
33
|
+
| [`deleteTeam`](#op-deleteteam) | `DELETE /api/v1/teams/{team_id}` | destructive | `team:delete` | Delete Team |
|
|
34
|
+
| [`getTeam`](#op-getteam) | `GET /api/v1/teams/{team_id}` | read | `team:read` | Get Team |
|
|
35
|
+
| [`listAvailableAgents`](#op-listavailableagents) | `GET /api/v1/teams/available/agents` | read | `team:read` | List Available Agents |
|
|
36
|
+
| [`listAvailableCampaigns`](#op-listavailablecampaigns) | `GET /api/v1/teams/available/campaigns` | read | `team:read` | List Available Campaigns |
|
|
37
|
+
| [`listAvailableChatbots`](#op-listavailablechatbots) | `GET /api/v1/teams/available/chatbots` | read | `team:read` | List Available Chatbots |
|
|
38
|
+
| [`listAvailableLinkedinAccounts`](#op-listavailablelinkedinaccounts) | `GET /api/v1/teams/available/linkedin-accounts` | read | `team:read` | List Available Linkedin Accounts |
|
|
39
|
+
| [`listAvailableMailboxes`](#op-listavailablemailboxes) | `GET /api/v1/teams/available/mailboxes` | read | `team:read` | List Available Mailboxes |
|
|
40
|
+
| [`listAvailablePhoneNumbers`](#op-listavailablephonenumbers) | `GET /api/v1/teams/available/phone-numbers` | read | `team:read` | List Available Phone Numbers |
|
|
41
|
+
| [`listAvailableSequences`](#op-listavailablesequences) | `GET /api/v1/teams/available/sequences` | read | `team:read` | List Available Sequences |
|
|
42
|
+
| [`listTeamAgents`](#op-listteamagents) | `GET /api/v1/teams/{team_id}/agents` | read | `team:read` | List Team Agents |
|
|
43
|
+
| [`listTeamCampaigns`](#op-listteamcampaigns) | `GET /api/v1/teams/{team_id}/campaigns` | read | `team:read` | List Team Campaigns |
|
|
44
|
+
| [`listTeamChatbots`](#op-listteamchatbots) | `GET /api/v1/teams/{team_id}/chatbots` | read | `team:read` | List Team Chatbots |
|
|
45
|
+
| [`listTeamLinkedinAccounts`](#op-listteamlinkedinaccounts) | `GET /api/v1/teams/{team_id}/linkedin-accounts` | read | `team:read` | List Team Linkedin Accounts |
|
|
46
|
+
| [`listTeamMailboxes`](#op-listteammailboxes) | `GET /api/v1/teams/{team_id}/mailboxes` | read | `team:read` | List Team Mailboxes |
|
|
47
|
+
| [`listTeamPhoneNumbers`](#op-listteamphonenumbers) | `GET /api/v1/teams/{team_id}/phone-numbers` | read | `team:read` | List Team Phone Numbers |
|
|
48
|
+
| [`listTeamSequences`](#op-listteamsequences) | `GET /api/v1/teams/{team_id}/sequences` | read | `team:read` | List Team Sequences |
|
|
49
|
+
| [`listTeams`](#op-listteams) | `GET /api/v1/teams` | read | `team:read` | List Teams |
|
|
50
|
+
| [`removeTeamAgent`](#op-removeteamagent) | `DELETE /api/v1/teams/{team_id}/agents/{user_id}` | destructive | `team:delete` | Remove Team Agent |
|
|
51
|
+
| [`removeTeamMember`](#op-removeteammember) | `DELETE /api/v1/teams/{team_id}/members/{user_id}` | destructive | `team:delete` | Remove Team Member |
|
|
52
|
+
| [`unassignCampaignFromTeam`](#op-unassigncampaignfromteam) | `DELETE /api/v1/teams/{team_id}/campaigns/{campaign_id}` | destructive | `team:delete` | Unassign Campaign From Team |
|
|
53
|
+
| [`unassignLinkedinAccountByAssoc`](#op-unassignlinkedinaccountbyassoc) | `DELETE /api/v1/teams/{team_id}/linkedin-accounts/assoc/{assoc_id}` | destructive | `team:delete` | Unassign Linkedin Account By Assoc |
|
|
54
|
+
| [`unassignLinkedinAccountFromTeam`](#op-unassignlinkedinaccountfromteam) | `DELETE /api/v1/teams/{team_id}/linkedin-accounts/{linkedin_account_id}` | destructive | `team:delete` | Unassign Linkedin Account From Team |
|
|
55
|
+
| [`unassignMailboxFromTeam`](#op-unassignmailboxfromteam) | `DELETE /api/v1/teams/{team_id}/mailboxes/{mailbox_id}` | destructive | `team:delete` | Unassign Mailbox From Team |
|
|
56
|
+
| [`unassignPhoneFromTeam`](#op-unassignphonefromteam) | `DELETE /api/v1/teams/{team_id}/phone-numbers/{phone_id}` | destructive | `team:delete` | Unassign Phone From Team |
|
|
57
|
+
| [`updateTeam`](#op-updateteam) | `PUT /api/v1/teams/{team_id}` | write | `team:write` | Update Team |
|
|
58
|
+
| [`updateTeamAgentRole`](#op-updateteamagentrole) | `PATCH /api/v1/teams/{team_id}/agents/{user_id}` | destructive | `team:delete` | Update Team Agent Role |
|
|
59
|
+
| [`updateTeamMemberRole`](#op-updateteammemberrole) | `PUT /api/v1/teams/{team_id}/members/{user_id}` | destructive | `team:delete` | Update Team Member Role |
|
|
60
|
+
|
|
61
|
+
---
|
|
62
|
+
|
|
63
|
+
<a id="op-addteamagent"></a>
|
|
64
|
+
|
|
65
|
+
### `g8.api.teams.addTeamAgent(input)`
|
|
66
|
+
|
|
67
|
+
**Add Team Agent**
|
|
68
|
+
|
|
69
|
+
- HTTP: `POST /api/v1/teams/{team_id}/agents`
|
|
70
|
+
- operationId: `add_team_agent_teams__team_id__agents_post` (also callable as `g8.api.call("add_team_agent_teams__team_id__agents_post", input)`)
|
|
71
|
+
- Tier: `write`: creates or changes records; the SDK sends an Idempotency-Key and retries transient failures
|
|
72
|
+
- API-key scope: `team:write`
|
|
73
|
+
|
|
74
|
+
Put an AI agent on a team.
|
|
75
|
+
|
|
76
|
+
An agent member is scoped exactly like a human one: it sees what the team
|
|
77
|
+
sees. Delegated authority is bounded by the delegator's, so an agent
|
|
78
|
+
cannot be given reach the caller does not have.
|
|
79
|
+
|
|
80
|
+
**Input**
|
|
81
|
+
|
|
82
|
+
| Field | Type | Required | Description |
|
|
83
|
+
|---|---|---|---|
|
|
84
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
85
|
+
| `body` | `TeamMemberAddRequest` | yes | Request body; fields below. |
|
|
86
|
+
|
|
87
|
+
Body fields (`TeamMemberAddRequest`):
|
|
88
|
+
|
|
89
|
+
| Field | Type | Required | Description |
|
|
90
|
+
|---|---|---|---|
|
|
91
|
+
| `body.user_id` | `string` | yes | min length 1, max length 255 |
|
|
92
|
+
| `body.team_role` | `string` | no | default `"member"`, max length 20 |
|
|
93
|
+
|
|
94
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
95
|
+
|
|
96
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
97
|
+
|
|
98
|
+
**Example**
|
|
99
|
+
|
|
100
|
+
```ts
|
|
101
|
+
const result = await g8.api.teams.addTeamAgent({ path: { team_id: "id" }, body: { user_id: "id" } });
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
---
|
|
105
|
+
|
|
106
|
+
<a id="op-addteammember"></a>
|
|
107
|
+
|
|
108
|
+
### `g8.api.teams.addTeamMember(input)`
|
|
109
|
+
|
|
110
|
+
**Add Team Member**
|
|
111
|
+
|
|
112
|
+
- HTTP: `POST /api/v1/teams/{team_id}/members`
|
|
113
|
+
- operationId: `add_team_member_teams__team_id__members_post` (also callable as `g8.api.call("add_team_member_teams__team_id__members_post", input)`)
|
|
114
|
+
- Tier: `write`: creates or changes records; the SDK sends an Idempotency-Key and retries transient failures
|
|
115
|
+
- API-key scope: `team:write`
|
|
116
|
+
|
|
117
|
+
Put a person on a team.
|
|
118
|
+
|
|
119
|
+
This WIDENS what they can see: every `:team`-scoped permission they hold
|
|
120
|
+
now resolves against this team's records too.
|
|
121
|
+
|
|
122
|
+
**Input**
|
|
123
|
+
|
|
124
|
+
| Field | Type | Required | Description |
|
|
125
|
+
|---|---|---|---|
|
|
126
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
127
|
+
| `body` | `TeamMemberAddRequest` | yes | Request body; fields below. |
|
|
128
|
+
|
|
129
|
+
Body fields (`TeamMemberAddRequest`):
|
|
130
|
+
|
|
131
|
+
| Field | Type | Required | Description |
|
|
132
|
+
|---|---|---|---|
|
|
133
|
+
| `body.user_id` | `string` | yes | min length 1, max length 255 |
|
|
134
|
+
| `body.team_role` | `string` | no | default `"member"`, max length 20 |
|
|
135
|
+
|
|
136
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
137
|
+
|
|
138
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
139
|
+
|
|
140
|
+
**Example**
|
|
141
|
+
|
|
142
|
+
```ts
|
|
143
|
+
const result = await g8.api.teams.addTeamMember({ path: { team_id: "id" }, body: { user_id: "id" } });
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
---
|
|
147
|
+
|
|
148
|
+
<a id="op-assigncampaigntoteam"></a>
|
|
149
|
+
|
|
150
|
+
### `g8.api.teams.assignCampaignToTeam(input)`
|
|
151
|
+
|
|
152
|
+
**Assign Campaign To Team**
|
|
153
|
+
|
|
154
|
+
- HTTP: `POST /api/v1/teams/{team_id}/campaigns`
|
|
155
|
+
- operationId: `assign_campaign_to_team_teams__team_id__campaigns_post` (also callable as `g8.api.call("assign_campaign_to_team_teams__team_id__campaigns_post", input)`)
|
|
156
|
+
- Tier: `write`: creates or changes records; the SDK sends an Idempotency-Key and retries transient failures
|
|
157
|
+
- API-key scope: `team:write`
|
|
158
|
+
|
|
159
|
+
Link a campaign to a team. It does not start or stop anything.
|
|
160
|
+
|
|
161
|
+
**Input**
|
|
162
|
+
|
|
163
|
+
| Field | Type | Required | Description |
|
|
164
|
+
|---|---|---|---|
|
|
165
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
166
|
+
| `body` | `AssignTeamCampaignRequest` | yes | Request body; fields below. |
|
|
167
|
+
|
|
168
|
+
Body fields (`AssignTeamCampaignRequest`):
|
|
169
|
+
|
|
170
|
+
| Field | Type | Required | Description |
|
|
171
|
+
|---|---|---|---|
|
|
172
|
+
| `body.campaign_id` | `string` | yes | UUID of the campaign to link to this team. |
|
|
173
|
+
|
|
174
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
175
|
+
|
|
176
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
177
|
+
|
|
178
|
+
**Example**
|
|
179
|
+
|
|
180
|
+
```ts
|
|
181
|
+
const result = await g8.api.teams.assignCampaignToTeam({ path: { team_id: "id" }, body: { campaign_id: "id" } });
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
---
|
|
185
|
+
|
|
186
|
+
<a id="op-assignlinkedinaccounttoteam"></a>
|
|
187
|
+
|
|
188
|
+
### `g8.api.teams.assignLinkedinAccountToTeam(input)`
|
|
189
|
+
|
|
190
|
+
**Assign Linkedin Account To Team**
|
|
191
|
+
|
|
192
|
+
- HTTP: `POST /api/v1/teams/{team_id}/linkedin-accounts`
|
|
193
|
+
- operationId: `assign_linkedin_account_to_team_teams__team_id__linkedin_accounts_post` (also callable as `g8.api.call("assign_linkedin_account_to_team_teams__team_id__linkedin_accounts_post", input)`)
|
|
194
|
+
- Tier: `write`: creates or changes records; the SDK sends an Idempotency-Key and retries transient failures
|
|
195
|
+
- API-key scope: `team:write`
|
|
196
|
+
|
|
197
|
+
Attach a LinkedIn sending account to a team.
|
|
198
|
+
|
|
199
|
+
Two spellings, both accepted because the app accepts both: the current
|
|
200
|
+
`provider` + `account_ref` pair from
|
|
201
|
+
`GET /teams/available/linkedin-accounts`, or the legacy
|
|
202
|
+
`linkedin_account_id`. Send the pair for new integrations - the legacy id
|
|
203
|
+
is ambiguous across providers.
|
|
204
|
+
|
|
205
|
+
**Input**
|
|
206
|
+
|
|
207
|
+
| Field | Type | Required | Description |
|
|
208
|
+
|---|---|---|---|
|
|
209
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
210
|
+
| `body` | `AssignLinkedInAccountRequest` | yes | Request body; fields below. |
|
|
211
|
+
|
|
212
|
+
Body fields (`AssignLinkedInAccountRequest`):
|
|
213
|
+
|
|
214
|
+
| Field | Type | Required | Description |
|
|
215
|
+
|---|---|---|---|
|
|
216
|
+
| `body.account_ref` | `string \| null` | no | The provider's own account key. |
|
|
217
|
+
| `body.linkedin_account_id` | `string (uuid) \| null` | no | Legacy account id. |
|
|
218
|
+
| `body.provider` | `string \| null` | no | Which LinkedIn provider the account belongs to. |
|
|
219
|
+
|
|
220
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
221
|
+
|
|
222
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
223
|
+
|
|
224
|
+
**Example**
|
|
225
|
+
|
|
226
|
+
```ts
|
|
227
|
+
const result = await g8.api.teams.assignLinkedinAccountToTeam({ path: { team_id: "id" }, body: {} });
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
---
|
|
231
|
+
|
|
232
|
+
<a id="op-assignmailboxtoteam"></a>
|
|
233
|
+
|
|
234
|
+
### `g8.api.teams.assignMailboxToTeam(input)`
|
|
235
|
+
|
|
236
|
+
**Assign Mailbox To Team**
|
|
237
|
+
|
|
238
|
+
- HTTP: `POST /api/v1/teams/{team_id}/mailboxes`
|
|
239
|
+
- operationId: `assign_mailbox_to_team_teams__team_id__mailboxes_post` (also callable as `g8.api.call("assign_mailbox_to_team_teams__team_id__mailboxes_post", input)`)
|
|
240
|
+
- Tier: `write`: creates or changes records; the SDK sends an Idempotency-Key and retries transient failures
|
|
241
|
+
- API-key scope: `team:write`
|
|
242
|
+
|
|
243
|
+
Attach a mailbox to a team. Everyone on the team may then send from it.
|
|
244
|
+
|
|
245
|
+
`object_id` is the integer `mailboxes.id` from
|
|
246
|
+
`GET /teams/available/mailboxes`, not the mailbox address.
|
|
247
|
+
|
|
248
|
+
**Input**
|
|
249
|
+
|
|
250
|
+
| Field | Type | Required | Description |
|
|
251
|
+
|---|---|---|---|
|
|
252
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
253
|
+
| `body` | `AssignObjectRequest` | yes | Request body; fields below. |
|
|
254
|
+
|
|
255
|
+
Body fields (`AssignObjectRequest`):
|
|
256
|
+
|
|
257
|
+
| Field | Type | Required | Description |
|
|
258
|
+
|---|---|---|---|
|
|
259
|
+
| `body.object_id` | `integer` | yes | Integer id of the mailbox or phone number to attach. |
|
|
260
|
+
|
|
261
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
262
|
+
|
|
263
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
264
|
+
|
|
265
|
+
**Example**
|
|
266
|
+
|
|
267
|
+
```ts
|
|
268
|
+
const result = await g8.api.teams.assignMailboxToTeam({ path: { team_id: "id" }, body: { object_id: 123 } });
|
|
269
|
+
```
|
|
270
|
+
|
|
271
|
+
---
|
|
272
|
+
|
|
273
|
+
<a id="op-assignphonetoteam"></a>
|
|
274
|
+
|
|
275
|
+
### `g8.api.teams.assignPhoneToTeam(input)`
|
|
276
|
+
|
|
277
|
+
**Assign Phone To Team**
|
|
278
|
+
|
|
279
|
+
- HTTP: `POST /api/v1/teams/{team_id}/phone-numbers`
|
|
280
|
+
- operationId: `assign_phone_to_team_teams__team_id__phone_numbers_post` (also callable as `g8.api.call("assign_phone_to_team_teams__team_id__phone_numbers_post", input)`)
|
|
281
|
+
- Tier: `write`: creates or changes records; the SDK sends an Idempotency-Key and retries transient failures
|
|
282
|
+
- API-key scope: `team:write`
|
|
283
|
+
|
|
284
|
+
Attach a phone number to a team.
|
|
285
|
+
|
|
286
|
+
**Input**
|
|
287
|
+
|
|
288
|
+
| Field | Type | Required | Description |
|
|
289
|
+
|---|---|---|---|
|
|
290
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
291
|
+
| `body` | `AssignObjectRequest` | yes | Request body; fields below. |
|
|
292
|
+
|
|
293
|
+
Body fields (`AssignObjectRequest`):
|
|
294
|
+
|
|
295
|
+
| Field | Type | Required | Description |
|
|
296
|
+
|---|---|---|---|
|
|
297
|
+
| `body.object_id` | `integer` | yes | Integer id of the mailbox or phone number to attach. |
|
|
298
|
+
|
|
299
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
300
|
+
|
|
301
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
302
|
+
|
|
303
|
+
**Example**
|
|
304
|
+
|
|
305
|
+
```ts
|
|
306
|
+
const result = await g8.api.teams.assignPhoneToTeam({ path: { team_id: "id" }, body: { object_id: 123 } });
|
|
307
|
+
```
|
|
308
|
+
|
|
309
|
+
---
|
|
310
|
+
|
|
311
|
+
<a id="op-autocomposesuggest"></a>
|
|
312
|
+
|
|
313
|
+
### `g8.api.teams.autoComposeSuggest(input?)`
|
|
314
|
+
|
|
315
|
+
**Auto Compose Suggest**
|
|
316
|
+
|
|
317
|
+
- HTTP: `POST /api/v1/teams/auto-compose/suggest`
|
|
318
|
+
- operationId: `auto_compose_suggest_teams_auto_compose_suggest_post` (also callable as `g8.api.call("auto_compose_suggest_teams_auto_compose_suggest_post", input)`)
|
|
319
|
+
- Tier: `billable`: spends credits; the SDK never blindly retries it; confirm cost before bulk use
|
|
320
|
+
- API-key scope: `team:run`
|
|
321
|
+
|
|
322
|
+
Propose a team structure from the organisation's current universe.
|
|
323
|
+
|
|
324
|
+
THIS SPENDS CREDITS. It reads every member, mailbox, number, campaign and
|
|
325
|
+
sequence and runs a model over them, and the handler settles the usage
|
|
326
|
+
afterwards - which is why it gates on `team:run` rather than plain write.
|
|
327
|
+
|
|
328
|
+
It SUGGESTS only. Nothing is created until you send the result to
|
|
329
|
+
`POST /teams`.
|
|
330
|
+
|
|
331
|
+
**Input**: none.
|
|
332
|
+
|
|
333
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
334
|
+
|
|
335
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
336
|
+
|
|
337
|
+
**Example**
|
|
338
|
+
|
|
339
|
+
```ts
|
|
340
|
+
// billable: spends credits; the SDK never blindly retries it; confirm cost before bulk use.
|
|
341
|
+
const result = await g8.api.teams.autoComposeSuggest();
|
|
342
|
+
```
|
|
343
|
+
|
|
344
|
+
---
|
|
345
|
+
|
|
346
|
+
<a id="op-createteam"></a>
|
|
347
|
+
|
|
348
|
+
### `g8.api.teams.createTeam(input)`
|
|
349
|
+
|
|
350
|
+
**Create Team**
|
|
351
|
+
|
|
352
|
+
- HTTP: `POST /api/v1/teams`
|
|
353
|
+
- operationId: `create_team_teams_post` (also callable as `g8.api.call("create_team_teams_post", input)`)
|
|
354
|
+
- Tier: `write`: creates or changes records; the SDK sends an Idempotency-Key and retries transient failures
|
|
355
|
+
- API-key scope: `team:write`
|
|
356
|
+
|
|
357
|
+
Create a team, with its members and channels, in ONE transaction.
|
|
358
|
+
|
|
359
|
+
Everything in the body lands atomically: a team is never briefly visible
|
|
360
|
+
with none of its mailboxes attached, and a rejected member id rolls the
|
|
361
|
+
whole thing back rather than leaving a half-built team.
|
|
362
|
+
|
|
363
|
+
409 when the name is already taken in this organisation.
|
|
364
|
+
|
|
365
|
+
**Input**
|
|
366
|
+
|
|
367
|
+
| Field | Type | Required | Description |
|
|
368
|
+
|---|---|---|---|
|
|
369
|
+
| `body` | `TeamCreateRequest` | yes | Request body; fields below. |
|
|
370
|
+
|
|
371
|
+
Body fields (`TeamCreateRequest`):
|
|
372
|
+
|
|
373
|
+
| Field | Type | Required | Description |
|
|
374
|
+
|---|---|---|---|
|
|
375
|
+
| `body.name` | `string` | yes | min length 1, max length 100 |
|
|
376
|
+
| `body.agent_id` | `string \| null` | no | max length 255 |
|
|
377
|
+
| `body.campaign_ids` | `Array<string (uuid)> \| null` | no | |
|
|
378
|
+
| `body.chat_intent` | `string \| null` | no | 'support' \| 'sales' \| null |
|
|
379
|
+
| `body.chatbot_ids` | `Array<string (uuid)> \| null` | no | |
|
|
380
|
+
| `body.color` | `string \| null` | no | Hex colour, e.g. #FF5733. An empty string clears it. max length 20, pattern `^(#[0-9A-Fa-f]{6})?$` |
|
|
381
|
+
| `body.description` | `string \| null` | no | |
|
|
382
|
+
| `body.linkedin_account_ids` | `Array<string (uuid)> \| null` | no | |
|
|
383
|
+
| `body.mailbox_ids` | `Array<integer> \| null` | no | |
|
|
384
|
+
| `body.members` | `Array<WorkspaceMemberInput> \| null` | no | |
|
|
385
|
+
| `body.phone_number_ids` | `Array<integer> \| null` | no | |
|
|
386
|
+
| `body.sequence_ids` | `Array<string> \| null` | no | |
|
|
387
|
+
| `body.type` | `string` | no | default `"functional"`, max length 50 |
|
|
388
|
+
|
|
389
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
390
|
+
|
|
391
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
392
|
+
|
|
393
|
+
**Example**
|
|
394
|
+
|
|
395
|
+
```ts
|
|
396
|
+
const result = await g8.api.teams.createTeam({ body: { name: "Example" } });
|
|
397
|
+
```
|
|
398
|
+
|
|
399
|
+
---
|
|
400
|
+
|
|
401
|
+
<a id="op-deleteteam"></a>
|
|
402
|
+
|
|
403
|
+
### `g8.api.teams.deleteTeam(input)`
|
|
404
|
+
|
|
405
|
+
**Delete Team**
|
|
406
|
+
|
|
407
|
+
- HTTP: `DELETE /api/v1/teams/{team_id}`
|
|
408
|
+
- operationId: `delete_team_teams__team_id__delete` (also callable as `g8.api.call("delete_team_teams__team_id__delete", input)`)
|
|
409
|
+
- Tier: `destructive`: deletes or archives data; confirm with a human before calling
|
|
410
|
+
- API-key scope: `team:delete`
|
|
411
|
+
|
|
412
|
+
Delete a team.
|
|
413
|
+
|
|
414
|
+
Everyone who was on it loses whatever `:team`-scoped visibility the
|
|
415
|
+
membership gave them. The records themselves are untouched.
|
|
416
|
+
|
|
417
|
+
**Input**
|
|
418
|
+
|
|
419
|
+
| Field | Type | Required | Description |
|
|
420
|
+
|---|---|---|---|
|
|
421
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
422
|
+
|
|
423
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
424
|
+
|
|
425
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
426
|
+
|
|
427
|
+
**Example**
|
|
428
|
+
|
|
429
|
+
```ts
|
|
430
|
+
// destructive: deletes or archives data; confirm with a human before calling.
|
|
431
|
+
const result = await g8.api.teams.deleteTeam({ path: { team_id: "id" } });
|
|
432
|
+
```
|
|
433
|
+
|
|
434
|
+
---
|
|
435
|
+
|
|
436
|
+
<a id="op-getteam"></a>
|
|
437
|
+
|
|
438
|
+
### `g8.api.teams.getTeam(input)`
|
|
439
|
+
|
|
440
|
+
**Get Team**
|
|
441
|
+
|
|
442
|
+
- HTTP: `GET /api/v1/teams/{team_id}`
|
|
443
|
+
- operationId: `get_team_teams__team_id__get` (also callable as `g8.api.call("get_team_teams__team_id__get", input)`)
|
|
444
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
445
|
+
- API-key scope: `team:read`
|
|
446
|
+
|
|
447
|
+
One team, with its full membership list.
|
|
448
|
+
|
|
449
|
+
**Input**
|
|
450
|
+
|
|
451
|
+
| Field | Type | Required | Description |
|
|
452
|
+
|---|---|---|---|
|
|
453
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
454
|
+
|
|
455
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
456
|
+
|
|
457
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
458
|
+
|
|
459
|
+
**Example**
|
|
460
|
+
|
|
461
|
+
```ts
|
|
462
|
+
const result = await g8.api.teams.getTeam({ path: { team_id: "id" } });
|
|
463
|
+
```
|
|
464
|
+
|
|
465
|
+
---
|
|
466
|
+
|
|
467
|
+
<a id="op-listavailableagents"></a>
|
|
468
|
+
|
|
469
|
+
### `g8.api.teams.listAvailableAgents(input?)`
|
|
470
|
+
|
|
471
|
+
**List Available Agents**
|
|
472
|
+
|
|
473
|
+
- HTTP: `GET /api/v1/teams/available/agents`
|
|
474
|
+
- operationId: `list_available_agents_teams_available_agents_get` (also callable as `g8.api.call("list_available_agents_teams_available_agents_get", input)`)
|
|
475
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
476
|
+
- API-key scope: `team:read`
|
|
477
|
+
|
|
478
|
+
AI agents that can be put on a team.
|
|
479
|
+
|
|
480
|
+
**Input**: none.
|
|
481
|
+
|
|
482
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
483
|
+
|
|
484
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
485
|
+
|
|
486
|
+
`OrgListPayload` fields:
|
|
487
|
+
|
|
488
|
+
| Field | Type | Required | Description |
|
|
489
|
+
|---|---|---|---|
|
|
490
|
+
| `items` | `Array<unknown>` | no | |
|
|
491
|
+
|
|
492
|
+
**Example**
|
|
493
|
+
|
|
494
|
+
```ts
|
|
495
|
+
const result = await g8.api.teams.listAvailableAgents();
|
|
496
|
+
```
|
|
497
|
+
|
|
498
|
+
---
|
|
499
|
+
|
|
500
|
+
<a id="op-listavailablecampaigns"></a>
|
|
501
|
+
|
|
502
|
+
### `g8.api.teams.listAvailableCampaigns(input?)`
|
|
503
|
+
|
|
504
|
+
**List Available Campaigns**
|
|
505
|
+
|
|
506
|
+
- HTTP: `GET /api/v1/teams/available/campaigns`
|
|
507
|
+
- operationId: `list_available_campaigns_teams_available_campaigns_get` (also callable as `g8.api.call("list_available_campaigns_teams_available_campaigns_get", input)`)
|
|
508
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
509
|
+
- API-key scope: `team:read`
|
|
510
|
+
|
|
511
|
+
Campaigns that can be linked to a team.
|
|
512
|
+
|
|
513
|
+
**Input**: none.
|
|
514
|
+
|
|
515
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
516
|
+
|
|
517
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
518
|
+
|
|
519
|
+
`OrgListPayload` fields:
|
|
520
|
+
|
|
521
|
+
| Field | Type | Required | Description |
|
|
522
|
+
|---|---|---|---|
|
|
523
|
+
| `items` | `Array<unknown>` | no | |
|
|
524
|
+
|
|
525
|
+
**Example**
|
|
526
|
+
|
|
527
|
+
```ts
|
|
528
|
+
const result = await g8.api.teams.listAvailableCampaigns();
|
|
529
|
+
```
|
|
530
|
+
|
|
531
|
+
---
|
|
532
|
+
|
|
533
|
+
<a id="op-listavailablechatbots"></a>
|
|
534
|
+
|
|
535
|
+
### `g8.api.teams.listAvailableChatbots(input?)`
|
|
536
|
+
|
|
537
|
+
**List Available Chatbots**
|
|
538
|
+
|
|
539
|
+
- HTTP: `GET /api/v1/teams/available/chatbots`
|
|
540
|
+
- operationId: `list_available_chatbots_teams_available_chatbots_get` (also callable as `g8.api.call("list_available_chatbots_teams_available_chatbots_get", input)`)
|
|
541
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
542
|
+
- API-key scope: `team:read`
|
|
543
|
+
|
|
544
|
+
Web chatbots that can be linked to a team.
|
|
545
|
+
|
|
546
|
+
**Input**: none.
|
|
547
|
+
|
|
548
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
549
|
+
|
|
550
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
551
|
+
|
|
552
|
+
`OrgListPayload` fields:
|
|
553
|
+
|
|
554
|
+
| Field | Type | Required | Description |
|
|
555
|
+
|---|---|---|---|
|
|
556
|
+
| `items` | `Array<unknown>` | no | |
|
|
557
|
+
|
|
558
|
+
**Example**
|
|
559
|
+
|
|
560
|
+
```ts
|
|
561
|
+
const result = await g8.api.teams.listAvailableChatbots();
|
|
562
|
+
```
|
|
563
|
+
|
|
564
|
+
---
|
|
565
|
+
|
|
566
|
+
<a id="op-listavailablelinkedinaccounts"></a>
|
|
567
|
+
|
|
568
|
+
### `g8.api.teams.listAvailableLinkedinAccounts(input?)`
|
|
569
|
+
|
|
570
|
+
**List Available Linkedin Accounts**
|
|
571
|
+
|
|
572
|
+
- HTTP: `GET /api/v1/teams/available/linkedin-accounts`
|
|
573
|
+
- operationId: `list_available_linkedin_accounts_teams_available_linkedin_accounts_get` (also callable as `g8.api.call("list_available_linkedin_accounts_teams_available_linkedin_accounts_get", input)`)
|
|
574
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
575
|
+
- API-key scope: `team:read`
|
|
576
|
+
|
|
577
|
+
LinkedIn sending accounts that can be attached to a team.
|
|
578
|
+
|
|
579
|
+
Spans both providers the organisation may be on, and the response says
|
|
580
|
+
which provider each account belongs to - that pair is what
|
|
581
|
+
`POST /teams/{team_id}/linkedin-accounts` wants.
|
|
582
|
+
|
|
583
|
+
**Input**: none.
|
|
584
|
+
|
|
585
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
586
|
+
|
|
587
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
588
|
+
|
|
589
|
+
`OrgListPayload` fields:
|
|
590
|
+
|
|
591
|
+
| Field | Type | Required | Description |
|
|
592
|
+
|---|---|---|---|
|
|
593
|
+
| `items` | `Array<unknown>` | no | |
|
|
594
|
+
|
|
595
|
+
**Example**
|
|
596
|
+
|
|
597
|
+
```ts
|
|
598
|
+
const result = await g8.api.teams.listAvailableLinkedinAccounts();
|
|
599
|
+
```
|
|
600
|
+
|
|
601
|
+
---
|
|
602
|
+
|
|
603
|
+
<a id="op-listavailablemailboxes"></a>
|
|
604
|
+
|
|
605
|
+
### `g8.api.teams.listAvailableMailboxes(input?)`
|
|
606
|
+
|
|
607
|
+
**List Available Mailboxes**
|
|
608
|
+
|
|
609
|
+
- HTTP: `GET /api/v1/teams/available/mailboxes`
|
|
610
|
+
- operationId: `list_available_mailboxes_teams_available_mailboxes_get` (also callable as `g8.api.call("list_available_mailboxes_teams_available_mailboxes_get", input)`)
|
|
611
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
612
|
+
- API-key scope: `team:read`
|
|
613
|
+
|
|
614
|
+
Mailboxes that can be attached to a team.
|
|
615
|
+
|
|
616
|
+
**Input**: none.
|
|
617
|
+
|
|
618
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
619
|
+
|
|
620
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
621
|
+
|
|
622
|
+
`OrgListPayload` fields:
|
|
623
|
+
|
|
624
|
+
| Field | Type | Required | Description |
|
|
625
|
+
|---|---|---|---|
|
|
626
|
+
| `items` | `Array<unknown>` | no | |
|
|
627
|
+
|
|
628
|
+
**Example**
|
|
629
|
+
|
|
630
|
+
```ts
|
|
631
|
+
const result = await g8.api.teams.listAvailableMailboxes();
|
|
632
|
+
```
|
|
633
|
+
|
|
634
|
+
---
|
|
635
|
+
|
|
636
|
+
<a id="op-listavailablephonenumbers"></a>
|
|
637
|
+
|
|
638
|
+
### `g8.api.teams.listAvailablePhoneNumbers(input?)`
|
|
639
|
+
|
|
640
|
+
**List Available Phone Numbers**
|
|
641
|
+
|
|
642
|
+
- HTTP: `GET /api/v1/teams/available/phone-numbers`
|
|
643
|
+
- operationId: `list_available_phone_numbers_teams_available_phone_numbers_get` (also callable as `g8.api.call("list_available_phone_numbers_teams_available_phone_numbers_get", input)`)
|
|
644
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
645
|
+
- API-key scope: `team:read`
|
|
646
|
+
|
|
647
|
+
Phone numbers that can be attached to a team.
|
|
648
|
+
|
|
649
|
+
**Input**: none.
|
|
650
|
+
|
|
651
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
652
|
+
|
|
653
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
654
|
+
|
|
655
|
+
`OrgListPayload` fields:
|
|
656
|
+
|
|
657
|
+
| Field | Type | Required | Description |
|
|
658
|
+
|---|---|---|---|
|
|
659
|
+
| `items` | `Array<unknown>` | no | |
|
|
660
|
+
|
|
661
|
+
**Example**
|
|
662
|
+
|
|
663
|
+
```ts
|
|
664
|
+
const result = await g8.api.teams.listAvailablePhoneNumbers();
|
|
665
|
+
```
|
|
666
|
+
|
|
667
|
+
---
|
|
668
|
+
|
|
669
|
+
<a id="op-listavailablesequences"></a>
|
|
670
|
+
|
|
671
|
+
### `g8.api.teams.listAvailableSequences(input?)`
|
|
672
|
+
|
|
673
|
+
**List Available Sequences**
|
|
674
|
+
|
|
675
|
+
- HTTP: `GET /api/v1/teams/available/sequences`
|
|
676
|
+
- operationId: `list_available_sequences_teams_available_sequences_get` (also callable as `g8.api.call("list_available_sequences_teams_available_sequences_get", input)`)
|
|
677
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
678
|
+
- API-key scope: `team:read`
|
|
679
|
+
|
|
680
|
+
Sequences that can be linked to a team.
|
|
681
|
+
|
|
682
|
+
**Input**: none.
|
|
683
|
+
|
|
684
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
685
|
+
|
|
686
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
687
|
+
|
|
688
|
+
`OrgListPayload` fields:
|
|
689
|
+
|
|
690
|
+
| Field | Type | Required | Description |
|
|
691
|
+
|---|---|---|---|
|
|
692
|
+
| `items` | `Array<unknown>` | no | |
|
|
693
|
+
|
|
694
|
+
**Example**
|
|
695
|
+
|
|
696
|
+
```ts
|
|
697
|
+
const result = await g8.api.teams.listAvailableSequences();
|
|
698
|
+
```
|
|
699
|
+
|
|
700
|
+
---
|
|
701
|
+
|
|
702
|
+
<a id="op-listteamagents"></a>
|
|
703
|
+
|
|
704
|
+
### `g8.api.teams.listTeamAgents(input)`
|
|
705
|
+
|
|
706
|
+
**List Team Agents**
|
|
707
|
+
|
|
708
|
+
- HTTP: `GET /api/v1/teams/{team_id}/agents`
|
|
709
|
+
- operationId: `list_team_agents_teams__team_id__agents_get` (also callable as `g8.api.call("list_team_agents_teams__team_id__agents_get", input)`)
|
|
710
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
711
|
+
- API-key scope: `team:read`
|
|
712
|
+
|
|
713
|
+
The AI agents that are members of this team.
|
|
714
|
+
|
|
715
|
+
**Input**
|
|
716
|
+
|
|
717
|
+
| Field | Type | Required | Description |
|
|
718
|
+
|---|---|---|---|
|
|
719
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
720
|
+
|
|
721
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
722
|
+
|
|
723
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
724
|
+
|
|
725
|
+
`OrgListPayload` fields:
|
|
726
|
+
|
|
727
|
+
| Field | Type | Required | Description |
|
|
728
|
+
|---|---|---|---|
|
|
729
|
+
| `items` | `Array<unknown>` | no | |
|
|
730
|
+
|
|
731
|
+
**Example**
|
|
732
|
+
|
|
733
|
+
```ts
|
|
734
|
+
const result = await g8.api.teams.listTeamAgents({ path: { team_id: "id" } });
|
|
735
|
+
```
|
|
736
|
+
|
|
737
|
+
---
|
|
738
|
+
|
|
739
|
+
<a id="op-listteamcampaigns"></a>
|
|
740
|
+
|
|
741
|
+
### `g8.api.teams.listTeamCampaigns(input)`
|
|
742
|
+
|
|
743
|
+
**List Team Campaigns**
|
|
744
|
+
|
|
745
|
+
- HTTP: `GET /api/v1/teams/{team_id}/campaigns`
|
|
746
|
+
- operationId: `list_team_campaigns_teams__team_id__campaigns_get` (also callable as `g8.api.call("list_team_campaigns_teams__team_id__campaigns_get", input)`)
|
|
747
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
748
|
+
- API-key scope: `team:read`
|
|
749
|
+
|
|
750
|
+
The campaigns this team runs.
|
|
751
|
+
|
|
752
|
+
**Input**
|
|
753
|
+
|
|
754
|
+
| Field | Type | Required | Description |
|
|
755
|
+
|---|---|---|---|
|
|
756
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
757
|
+
|
|
758
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
759
|
+
|
|
760
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
761
|
+
|
|
762
|
+
`OrgListPayload` fields:
|
|
763
|
+
|
|
764
|
+
| Field | Type | Required | Description |
|
|
765
|
+
|---|---|---|---|
|
|
766
|
+
| `items` | `Array<unknown>` | no | |
|
|
767
|
+
|
|
768
|
+
**Example**
|
|
769
|
+
|
|
770
|
+
```ts
|
|
771
|
+
const result = await g8.api.teams.listTeamCampaigns({ path: { team_id: "id" } });
|
|
772
|
+
```
|
|
773
|
+
|
|
774
|
+
---
|
|
775
|
+
|
|
776
|
+
<a id="op-listteamchatbots"></a>
|
|
777
|
+
|
|
778
|
+
### `g8.api.teams.listTeamChatbots(input)`
|
|
779
|
+
|
|
780
|
+
**List Team Chatbots**
|
|
781
|
+
|
|
782
|
+
- HTTP: `GET /api/v1/teams/{team_id}/chatbots`
|
|
783
|
+
- operationId: `list_team_chatbots_teams__team_id__chatbots_get` (also callable as `g8.api.call("list_team_chatbots_teams__team_id__chatbots_get", input)`)
|
|
784
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
785
|
+
- API-key scope: `team:read`
|
|
786
|
+
|
|
787
|
+
The web chatbots routed to this team.
|
|
788
|
+
|
|
789
|
+
**Input**
|
|
790
|
+
|
|
791
|
+
| Field | Type | Required | Description |
|
|
792
|
+
|---|---|---|---|
|
|
793
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
794
|
+
|
|
795
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
796
|
+
|
|
797
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
798
|
+
|
|
799
|
+
`OrgListPayload` fields:
|
|
800
|
+
|
|
801
|
+
| Field | Type | Required | Description |
|
|
802
|
+
|---|---|---|---|
|
|
803
|
+
| `items` | `Array<unknown>` | no | |
|
|
804
|
+
|
|
805
|
+
**Example**
|
|
806
|
+
|
|
807
|
+
```ts
|
|
808
|
+
const result = await g8.api.teams.listTeamChatbots({ path: { team_id: "id" } });
|
|
809
|
+
```
|
|
810
|
+
|
|
811
|
+
---
|
|
812
|
+
|
|
813
|
+
<a id="op-listteamlinkedinaccounts"></a>
|
|
814
|
+
|
|
815
|
+
### `g8.api.teams.listTeamLinkedinAccounts(input)`
|
|
816
|
+
|
|
817
|
+
**List Team Linkedin Accounts**
|
|
818
|
+
|
|
819
|
+
- HTTP: `GET /api/v1/teams/{team_id}/linkedin-accounts`
|
|
820
|
+
- operationId: `list_team_linkedin_accounts_teams__team_id__linkedin_accounts_get` (also callable as `g8.api.call("list_team_linkedin_accounts_teams__team_id__linkedin_accounts_get", input)`)
|
|
821
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
822
|
+
- API-key scope: `team:read`
|
|
823
|
+
|
|
824
|
+
The LinkedIn accounts this team may send from.
|
|
825
|
+
|
|
826
|
+
**Input**
|
|
827
|
+
|
|
828
|
+
| Field | Type | Required | Description |
|
|
829
|
+
|---|---|---|---|
|
|
830
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
831
|
+
|
|
832
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
833
|
+
|
|
834
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
835
|
+
|
|
836
|
+
`OrgListPayload` fields:
|
|
837
|
+
|
|
838
|
+
| Field | Type | Required | Description |
|
|
839
|
+
|---|---|---|---|
|
|
840
|
+
| `items` | `Array<unknown>` | no | |
|
|
841
|
+
|
|
842
|
+
**Example**
|
|
843
|
+
|
|
844
|
+
```ts
|
|
845
|
+
const result = await g8.api.teams.listTeamLinkedinAccounts({ path: { team_id: "id" } });
|
|
846
|
+
```
|
|
847
|
+
|
|
848
|
+
---
|
|
849
|
+
|
|
850
|
+
<a id="op-listteammailboxes"></a>
|
|
851
|
+
|
|
852
|
+
### `g8.api.teams.listTeamMailboxes(input)`
|
|
853
|
+
|
|
854
|
+
**List Team Mailboxes**
|
|
855
|
+
|
|
856
|
+
- HTTP: `GET /api/v1/teams/{team_id}/mailboxes`
|
|
857
|
+
- operationId: `list_team_mailboxes_teams__team_id__mailboxes_get` (also callable as `g8.api.call("list_team_mailboxes_teams__team_id__mailboxes_get", input)`)
|
|
858
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
859
|
+
- API-key scope: `team:read`
|
|
860
|
+
|
|
861
|
+
The mailboxes this team may send from.
|
|
862
|
+
|
|
863
|
+
**Input**
|
|
864
|
+
|
|
865
|
+
| Field | Type | Required | Description |
|
|
866
|
+
|---|---|---|---|
|
|
867
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
868
|
+
|
|
869
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
870
|
+
|
|
871
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
872
|
+
|
|
873
|
+
`OrgListPayload` fields:
|
|
874
|
+
|
|
875
|
+
| Field | Type | Required | Description |
|
|
876
|
+
|---|---|---|---|
|
|
877
|
+
| `items` | `Array<unknown>` | no | |
|
|
878
|
+
|
|
879
|
+
**Example**
|
|
880
|
+
|
|
881
|
+
```ts
|
|
882
|
+
const result = await g8.api.teams.listTeamMailboxes({ path: { team_id: "id" } });
|
|
883
|
+
```
|
|
884
|
+
|
|
885
|
+
---
|
|
886
|
+
|
|
887
|
+
<a id="op-listteamphonenumbers"></a>
|
|
888
|
+
|
|
889
|
+
### `g8.api.teams.listTeamPhoneNumbers(input)`
|
|
890
|
+
|
|
891
|
+
**List Team Phone Numbers**
|
|
892
|
+
|
|
893
|
+
- HTTP: `GET /api/v1/teams/{team_id}/phone-numbers`
|
|
894
|
+
- operationId: `list_team_phone_numbers_teams__team_id__phone_numbers_get` (also callable as `g8.api.call("list_team_phone_numbers_teams__team_id__phone_numbers_get", input)`)
|
|
895
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
896
|
+
- API-key scope: `team:read`
|
|
897
|
+
|
|
898
|
+
The phone numbers this team may call and text from.
|
|
899
|
+
|
|
900
|
+
**Input**
|
|
901
|
+
|
|
902
|
+
| Field | Type | Required | Description |
|
|
903
|
+
|---|---|---|---|
|
|
904
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
905
|
+
|
|
906
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
907
|
+
|
|
908
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
909
|
+
|
|
910
|
+
`OrgListPayload` fields:
|
|
911
|
+
|
|
912
|
+
| Field | Type | Required | Description |
|
|
913
|
+
|---|---|---|---|
|
|
914
|
+
| `items` | `Array<unknown>` | no | |
|
|
915
|
+
|
|
916
|
+
**Example**
|
|
917
|
+
|
|
918
|
+
```ts
|
|
919
|
+
const result = await g8.api.teams.listTeamPhoneNumbers({ path: { team_id: "id" } });
|
|
920
|
+
```
|
|
921
|
+
|
|
922
|
+
---
|
|
923
|
+
|
|
924
|
+
<a id="op-listteamsequences"></a>
|
|
925
|
+
|
|
926
|
+
### `g8.api.teams.listTeamSequences(input)`
|
|
927
|
+
|
|
928
|
+
**List Team Sequences**
|
|
929
|
+
|
|
930
|
+
- HTTP: `GET /api/v1/teams/{team_id}/sequences`
|
|
931
|
+
- operationId: `list_team_sequences_teams__team_id__sequences_get` (also callable as `g8.api.call("list_team_sequences_teams__team_id__sequences_get", input)`)
|
|
932
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
933
|
+
- API-key scope: `team:read`
|
|
934
|
+
|
|
935
|
+
The sequences this team runs.
|
|
936
|
+
|
|
937
|
+
**Input**
|
|
938
|
+
|
|
939
|
+
| Field | Type | Required | Description |
|
|
940
|
+
|---|---|---|---|
|
|
941
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
942
|
+
|
|
943
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
944
|
+
|
|
945
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
946
|
+
|
|
947
|
+
`OrgListPayload` fields:
|
|
948
|
+
|
|
949
|
+
| Field | Type | Required | Description |
|
|
950
|
+
|---|---|---|---|
|
|
951
|
+
| `items` | `Array<unknown>` | no | |
|
|
952
|
+
|
|
953
|
+
**Example**
|
|
954
|
+
|
|
955
|
+
```ts
|
|
956
|
+
const result = await g8.api.teams.listTeamSequences({ path: { team_id: "id" } });
|
|
957
|
+
```
|
|
958
|
+
|
|
959
|
+
---
|
|
960
|
+
|
|
961
|
+
<a id="op-listteams"></a>
|
|
962
|
+
|
|
963
|
+
### `g8.api.teams.listTeams(input?)`
|
|
964
|
+
|
|
965
|
+
**List Teams**
|
|
966
|
+
|
|
967
|
+
- HTTP: `GET /api/v1/teams`
|
|
968
|
+
- operationId: `list_teams_teams_get` (also callable as `g8.api.call("list_teams_teams_get", input)`)
|
|
969
|
+
- Tier: `read`: reads data; safe to call and to retry
|
|
970
|
+
- API-key scope: `team:read`
|
|
971
|
+
|
|
972
|
+
Every team in the organisation, with its channels and member preview.
|
|
973
|
+
|
|
974
|
+
All aggregates are computed in grouped queries, so this stays one round
|
|
975
|
+
trip however many teams there are.
|
|
976
|
+
|
|
977
|
+
**Input**: none.
|
|
978
|
+
|
|
979
|
+
**Returns** `ApiResponse_OrgListPayload_`: the envelope `{ data: OrgListPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
980
|
+
|
|
981
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
982
|
+
|
|
983
|
+
`OrgListPayload` fields:
|
|
984
|
+
|
|
985
|
+
| Field | Type | Required | Description |
|
|
986
|
+
|---|---|---|---|
|
|
987
|
+
| `items` | `Array<unknown>` | no | |
|
|
988
|
+
|
|
989
|
+
**Example**
|
|
990
|
+
|
|
991
|
+
```ts
|
|
992
|
+
const result = await g8.api.teams.listTeams();
|
|
993
|
+
```
|
|
994
|
+
|
|
995
|
+
---
|
|
996
|
+
|
|
997
|
+
<a id="op-removeteamagent"></a>
|
|
998
|
+
|
|
999
|
+
### `g8.api.teams.removeTeamAgent(input)`
|
|
1000
|
+
|
|
1001
|
+
**Remove Team Agent**
|
|
1002
|
+
|
|
1003
|
+
- HTTP: `DELETE /api/v1/teams/{team_id}/agents/{user_id}`
|
|
1004
|
+
- operationId: `remove_team_agent_teams__team_id__agents__user_id__delete` (also callable as `g8.api.call("remove_team_agent_teams__team_id__agents__user_id__delete", input)`)
|
|
1005
|
+
- Tier: `destructive`: deletes or archives data; confirm with a human before calling
|
|
1006
|
+
- API-key scope: `team:delete`
|
|
1007
|
+
|
|
1008
|
+
Take an AI agent off a team.
|
|
1009
|
+
|
|
1010
|
+
**Input**
|
|
1011
|
+
|
|
1012
|
+
| Field | Type | Required | Description |
|
|
1013
|
+
|---|---|---|---|
|
|
1014
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
1015
|
+
| `path.user_id` | `string` | yes | Agent user id. |
|
|
1016
|
+
|
|
1017
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
1018
|
+
|
|
1019
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
1020
|
+
|
|
1021
|
+
**Example**
|
|
1022
|
+
|
|
1023
|
+
```ts
|
|
1024
|
+
// destructive: deletes or archives data; confirm with a human before calling.
|
|
1025
|
+
const result = await g8.api.teams.removeTeamAgent({ path: { team_id: "id", user_id: "id" } });
|
|
1026
|
+
```
|
|
1027
|
+
|
|
1028
|
+
---
|
|
1029
|
+
|
|
1030
|
+
<a id="op-removeteammember"></a>
|
|
1031
|
+
|
|
1032
|
+
### `g8.api.teams.removeTeamMember(input)`
|
|
1033
|
+
|
|
1034
|
+
**Remove Team Member**
|
|
1035
|
+
|
|
1036
|
+
- HTTP: `DELETE /api/v1/teams/{team_id}/members/{user_id}`
|
|
1037
|
+
- operationId: `remove_team_member_teams__team_id__members__user_id__delete` (also callable as `g8.api.call("remove_team_member_teams__team_id__members__user_id__delete", input)`)
|
|
1038
|
+
- Tier: `destructive`: deletes or archives data; confirm with a human before calling
|
|
1039
|
+
- API-key scope: `team:delete`
|
|
1040
|
+
|
|
1041
|
+
Take a person off a team. They keep their org role; they lose the team.
|
|
1042
|
+
|
|
1043
|
+
**Input**
|
|
1044
|
+
|
|
1045
|
+
| Field | Type | Required | Description |
|
|
1046
|
+
|---|---|---|---|
|
|
1047
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
1048
|
+
| `path.user_id` | `string` | yes | Identity-provider user id. |
|
|
1049
|
+
|
|
1050
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
1051
|
+
|
|
1052
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
1053
|
+
|
|
1054
|
+
**Example**
|
|
1055
|
+
|
|
1056
|
+
```ts
|
|
1057
|
+
// destructive: deletes or archives data; confirm with a human before calling.
|
|
1058
|
+
const result = await g8.api.teams.removeTeamMember({ path: { team_id: "id", user_id: "id" } });
|
|
1059
|
+
```
|
|
1060
|
+
|
|
1061
|
+
---
|
|
1062
|
+
|
|
1063
|
+
<a id="op-unassigncampaignfromteam"></a>
|
|
1064
|
+
|
|
1065
|
+
### `g8.api.teams.unassignCampaignFromTeam(input)`
|
|
1066
|
+
|
|
1067
|
+
**Unassign Campaign From Team**
|
|
1068
|
+
|
|
1069
|
+
- HTTP: `DELETE /api/v1/teams/{team_id}/campaigns/{campaign_id}`
|
|
1070
|
+
- operationId: `unassign_campaign_from_team_teams__team_id__campaigns__campaign_id__delete` (also callable as `g8.api.call("unassign_campaign_from_team_teams__team_id__campaigns__campaign_id__delete", input)`)
|
|
1071
|
+
- Tier: `destructive`: deletes or archives data; confirm with a human before calling
|
|
1072
|
+
- API-key scope: `team:delete`
|
|
1073
|
+
|
|
1074
|
+
Unlink a campaign from a team. The campaign itself is untouched.
|
|
1075
|
+
|
|
1076
|
+
**Input**
|
|
1077
|
+
|
|
1078
|
+
| Field | Type | Required | Description |
|
|
1079
|
+
|---|---|---|---|
|
|
1080
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
1081
|
+
| `path.campaign_id` | `string` | yes | Campaign id (UUID). |
|
|
1082
|
+
|
|
1083
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
1084
|
+
|
|
1085
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
1086
|
+
|
|
1087
|
+
**Example**
|
|
1088
|
+
|
|
1089
|
+
```ts
|
|
1090
|
+
// destructive: deletes or archives data; confirm with a human before calling.
|
|
1091
|
+
const result = await g8.api.teams.unassignCampaignFromTeam({ path: { team_id: "id", campaign_id: "id" } });
|
|
1092
|
+
```
|
|
1093
|
+
|
|
1094
|
+
---
|
|
1095
|
+
|
|
1096
|
+
<a id="op-unassignlinkedinaccountbyassoc"></a>
|
|
1097
|
+
|
|
1098
|
+
### `g8.api.teams.unassignLinkedinAccountByAssoc(input)`
|
|
1099
|
+
|
|
1100
|
+
**Unassign Linkedin Account By Assoc**
|
|
1101
|
+
|
|
1102
|
+
- HTTP: `DELETE /api/v1/teams/{team_id}/linkedin-accounts/assoc/{assoc_id}`
|
|
1103
|
+
- operationId: `unassign_linkedin_account_by_assoc_teams__team_id__linkedin_accounts_assoc__assoc_id__delete` (also callable as `g8.api.call("unassign_linkedin_account_by_assoc_teams__team_id__linkedin_accounts_assoc__assoc_id__delete", input)`)
|
|
1104
|
+
- Tier: `destructive`: deletes or archives data; confirm with a human before calling
|
|
1105
|
+
- API-key scope: `team:delete`
|
|
1106
|
+
|
|
1107
|
+
Detach ONE association by its own id.
|
|
1108
|
+
|
|
1109
|
+
Use this rather than the account-id form when the same account is attached
|
|
1110
|
+
more than once: the account-id form removes whichever association it finds,
|
|
1111
|
+
and this names exactly the one you mean. Declared BEFORE the account-id
|
|
1112
|
+
route so the `assoc` literal is reachable.
|
|
1113
|
+
|
|
1114
|
+
**Input**
|
|
1115
|
+
|
|
1116
|
+
| Field | Type | Required | Description |
|
|
1117
|
+
|---|---|---|---|
|
|
1118
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
1119
|
+
| `path.assoc_id` | `string` | yes | Association row id (UUID). |
|
|
1120
|
+
|
|
1121
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
1122
|
+
|
|
1123
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
1124
|
+
|
|
1125
|
+
**Example**
|
|
1126
|
+
|
|
1127
|
+
```ts
|
|
1128
|
+
// destructive: deletes or archives data; confirm with a human before calling.
|
|
1129
|
+
const result = await g8.api.teams.unassignLinkedinAccountByAssoc({ path: { team_id: "id", assoc_id: "id" } });
|
|
1130
|
+
```
|
|
1131
|
+
|
|
1132
|
+
---
|
|
1133
|
+
|
|
1134
|
+
<a id="op-unassignlinkedinaccountfromteam"></a>
|
|
1135
|
+
|
|
1136
|
+
### `g8.api.teams.unassignLinkedinAccountFromTeam(input)`
|
|
1137
|
+
|
|
1138
|
+
**Unassign Linkedin Account From Team**
|
|
1139
|
+
|
|
1140
|
+
- HTTP: `DELETE /api/v1/teams/{team_id}/linkedin-accounts/{linkedin_account_id}`
|
|
1141
|
+
- operationId: `unassign_linkedin_account_from_team_teams__team_id__linkedin_accounts__linkedin_account_id__delete` (also callable as `g8.api.call("unassign_linkedin_account_from_team_teams__team_id__linkedin_accounts__linkedin_account_id__delete", input)`)
|
|
1142
|
+
- Tier: `destructive`: deletes or archives data; confirm with a human before calling
|
|
1143
|
+
- API-key scope: `team:delete`
|
|
1144
|
+
|
|
1145
|
+
Detach a LinkedIn account from a team.
|
|
1146
|
+
|
|
1147
|
+
**Input**
|
|
1148
|
+
|
|
1149
|
+
| Field | Type | Required | Description |
|
|
1150
|
+
|---|---|---|---|
|
|
1151
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
1152
|
+
| `path.linkedin_account_id` | `string` | yes | LinkedIn account id (UUID). |
|
|
1153
|
+
|
|
1154
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
1155
|
+
|
|
1156
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
1157
|
+
|
|
1158
|
+
**Example**
|
|
1159
|
+
|
|
1160
|
+
```ts
|
|
1161
|
+
// destructive: deletes or archives data; confirm with a human before calling.
|
|
1162
|
+
const result = await g8.api.teams.unassignLinkedinAccountFromTeam({ path: { team_id: "id", linkedin_account_id: "id" } });
|
|
1163
|
+
```
|
|
1164
|
+
|
|
1165
|
+
---
|
|
1166
|
+
|
|
1167
|
+
<a id="op-unassignmailboxfromteam"></a>
|
|
1168
|
+
|
|
1169
|
+
### `g8.api.teams.unassignMailboxFromTeam(input)`
|
|
1170
|
+
|
|
1171
|
+
**Unassign Mailbox From Team**
|
|
1172
|
+
|
|
1173
|
+
- HTTP: `DELETE /api/v1/teams/{team_id}/mailboxes/{mailbox_id}`
|
|
1174
|
+
- operationId: `unassign_mailbox_from_team_teams__team_id__mailboxes__mailbox_id__delete` (also callable as `g8.api.call("unassign_mailbox_from_team_teams__team_id__mailboxes__mailbox_id__delete", input)`)
|
|
1175
|
+
- Tier: `destructive`: deletes or archives data; confirm with a human before calling
|
|
1176
|
+
- API-key scope: `team:delete`
|
|
1177
|
+
|
|
1178
|
+
Detach a mailbox. The mailbox itself survives; the team loses access.
|
|
1179
|
+
|
|
1180
|
+
**Input**
|
|
1181
|
+
|
|
1182
|
+
| Field | Type | Required | Description |
|
|
1183
|
+
|---|---|---|---|
|
|
1184
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
1185
|
+
| `path.mailbox_id` | `integer` | yes | Integer `mailboxes.id`. |
|
|
1186
|
+
|
|
1187
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
1188
|
+
|
|
1189
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
1190
|
+
|
|
1191
|
+
**Example**
|
|
1192
|
+
|
|
1193
|
+
```ts
|
|
1194
|
+
// destructive: deletes or archives data; confirm with a human before calling.
|
|
1195
|
+
const result = await g8.api.teams.unassignMailboxFromTeam({ path: { team_id: "id", mailbox_id: 123 } });
|
|
1196
|
+
```
|
|
1197
|
+
|
|
1198
|
+
---
|
|
1199
|
+
|
|
1200
|
+
<a id="op-unassignphonefromteam"></a>
|
|
1201
|
+
|
|
1202
|
+
### `g8.api.teams.unassignPhoneFromTeam(input)`
|
|
1203
|
+
|
|
1204
|
+
**Unassign Phone From Team**
|
|
1205
|
+
|
|
1206
|
+
- HTTP: `DELETE /api/v1/teams/{team_id}/phone-numbers/{phone_id}`
|
|
1207
|
+
- operationId: `unassign_phone_from_team_teams__team_id__phone_numbers__phone_id__delete` (also callable as `g8.api.call("unassign_phone_from_team_teams__team_id__phone_numbers__phone_id__delete", input)`)
|
|
1208
|
+
- Tier: `destructive`: deletes or archives data; confirm with a human before calling
|
|
1209
|
+
- API-key scope: `team:delete`
|
|
1210
|
+
|
|
1211
|
+
Detach a phone number from a team.
|
|
1212
|
+
|
|
1213
|
+
**Input**
|
|
1214
|
+
|
|
1215
|
+
| Field | Type | Required | Description |
|
|
1216
|
+
|---|---|---|---|
|
|
1217
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
1218
|
+
| `path.phone_id` | `integer` | yes | Integer phone-number id. |
|
|
1219
|
+
|
|
1220
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
1221
|
+
|
|
1222
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
1223
|
+
|
|
1224
|
+
**Example**
|
|
1225
|
+
|
|
1226
|
+
```ts
|
|
1227
|
+
// destructive: deletes or archives data; confirm with a human before calling.
|
|
1228
|
+
const result = await g8.api.teams.unassignPhoneFromTeam({ path: { team_id: "id", phone_id: 123 } });
|
|
1229
|
+
```
|
|
1230
|
+
|
|
1231
|
+
---
|
|
1232
|
+
|
|
1233
|
+
<a id="op-updateteam"></a>
|
|
1234
|
+
|
|
1235
|
+
### `g8.api.teams.updateTeam(input)`
|
|
1236
|
+
|
|
1237
|
+
**Update Team**
|
|
1238
|
+
|
|
1239
|
+
- HTTP: `PUT /api/v1/teams/{team_id}`
|
|
1240
|
+
- operationId: `update_team_teams__team_id__put` (also callable as `g8.api.call("update_team_teams__team_id__put", input)`)
|
|
1241
|
+
- Tier: `write`: creates or changes records; the SDK sends an Idempotency-Key and retries transient failures
|
|
1242
|
+
- API-key scope: `team:write`
|
|
1243
|
+
|
|
1244
|
+
Update a team, and optionally re-attach everything on it in one call.
|
|
1245
|
+
|
|
1246
|
+
An omitted `*_ids` list LEAVES that attachment alone. A list that IS
|
|
1247
|
+
present REPLACES it, so sending `[]` detaches every mailbox (or number, or
|
|
1248
|
+
campaign) the team had. Omitting and sending an empty list are different
|
|
1249
|
+
instructions and the second one is destructive - the handler diffs.
|
|
1250
|
+
|
|
1251
|
+
**Input**
|
|
1252
|
+
|
|
1253
|
+
| Field | Type | Required | Description |
|
|
1254
|
+
|---|---|---|---|
|
|
1255
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
1256
|
+
| `body` | `TeamUpdateRequest` | yes | Request body; fields below. |
|
|
1257
|
+
|
|
1258
|
+
Body fields (`TeamUpdateRequest`):
|
|
1259
|
+
|
|
1260
|
+
| Field | Type | Required | Description |
|
|
1261
|
+
|---|---|---|---|
|
|
1262
|
+
| `body.agent_id` | `string \| null` | no | Single workspace AI agent; empty string clears it. max length 255 |
|
|
1263
|
+
| `body.campaign_ids` | `Array<string (uuid)> \| null` | no | |
|
|
1264
|
+
| `body.chat_intent` | `string \| null` | no | 'support' \| 'sales' \| null. An empty string clears it. |
|
|
1265
|
+
| `body.chatbot_ids` | `Array<string (uuid)> \| null` | no | |
|
|
1266
|
+
| `body.color` | `string \| null` | no | Hex colour, e.g. #FF5733. An empty string clears it. max length 20, pattern `^(#[0-9A-Fa-f]{6})?$` |
|
|
1267
|
+
| `body.description` | `string \| null` | no | |
|
|
1268
|
+
| `body.linkedin_account_ids` | `Array<string (uuid)> \| null` | no | |
|
|
1269
|
+
| `body.mailbox_ids` | `Array<integer> \| null` | no | |
|
|
1270
|
+
| `body.members` | `Array<WorkspaceMemberInput> \| null` | no | |
|
|
1271
|
+
| `body.name` | `string \| null` | no | min length 1, max length 100 |
|
|
1272
|
+
| `body.phone_number_ids` | `Array<integer> \| null` | no | |
|
|
1273
|
+
| `body.sequence_ids` | `Array<string> \| null` | no | |
|
|
1274
|
+
| `body.type` | `string \| null` | no | max length 50 |
|
|
1275
|
+
|
|
1276
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
1277
|
+
|
|
1278
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
1279
|
+
|
|
1280
|
+
**Example**
|
|
1281
|
+
|
|
1282
|
+
```ts
|
|
1283
|
+
const result = await g8.api.teams.updateTeam({ path: { team_id: "id" }, body: {} });
|
|
1284
|
+
```
|
|
1285
|
+
|
|
1286
|
+
---
|
|
1287
|
+
|
|
1288
|
+
<a id="op-updateteamagentrole"></a>
|
|
1289
|
+
|
|
1290
|
+
### `g8.api.teams.updateTeamAgentRole(input)`
|
|
1291
|
+
|
|
1292
|
+
**Update Team Agent Role**
|
|
1293
|
+
|
|
1294
|
+
- HTTP: `PATCH /api/v1/teams/{team_id}/agents/{user_id}`
|
|
1295
|
+
- operationId: `update_team_agent_role_teams__team_id__agents__user_id__patch` (also callable as `g8.api.call("update_team_agent_role_teams__team_id__agents__user_id__patch", input)`)
|
|
1296
|
+
- Tier: `destructive`: deletes or archives data; confirm with a human before calling
|
|
1297
|
+
- API-key scope: `team:delete`
|
|
1298
|
+
|
|
1299
|
+
Change an agent's role within this team. REPLACES the previous one.
|
|
1300
|
+
|
|
1301
|
+
Tiered `destructive` for the same reason as its human twin: it is a
|
|
1302
|
+
privilege change on a membership row, not an edit to a label.
|
|
1303
|
+
|
|
1304
|
+
**Input**
|
|
1305
|
+
|
|
1306
|
+
| Field | Type | Required | Description |
|
|
1307
|
+
|---|---|---|---|
|
|
1308
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
1309
|
+
| `path.user_id` | `string` | yes | Agent user id. |
|
|
1310
|
+
| `body` | `TeamMemberRoleUpdateRequest` | yes | Request body; fields below. |
|
|
1311
|
+
|
|
1312
|
+
Body fields (`TeamMemberRoleUpdateRequest`):
|
|
1313
|
+
|
|
1314
|
+
| Field | Type | Required | Description |
|
|
1315
|
+
|---|---|---|---|
|
|
1316
|
+
| `body.team_role` | `string` | yes | max length 20 |
|
|
1317
|
+
|
|
1318
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
1319
|
+
|
|
1320
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
1321
|
+
|
|
1322
|
+
**Example**
|
|
1323
|
+
|
|
1324
|
+
```ts
|
|
1325
|
+
// destructive: deletes or archives data; confirm with a human before calling.
|
|
1326
|
+
const result = await g8.api.teams.updateTeamAgentRole({
|
|
1327
|
+
path: { team_id: "id", user_id: "id" },
|
|
1328
|
+
body: { team_role: "example" },
|
|
1329
|
+
});
|
|
1330
|
+
```
|
|
1331
|
+
|
|
1332
|
+
---
|
|
1333
|
+
|
|
1334
|
+
<a id="op-updateteammemberrole"></a>
|
|
1335
|
+
|
|
1336
|
+
### `g8.api.teams.updateTeamMemberRole(input)`
|
|
1337
|
+
|
|
1338
|
+
**Update Team Member Role**
|
|
1339
|
+
|
|
1340
|
+
- HTTP: `PUT /api/v1/teams/{team_id}/members/{user_id}`
|
|
1341
|
+
- operationId: `update_team_member_role_teams__team_id__members__user_id__put` (also callable as `g8.api.call("update_team_member_role_teams__team_id__members__user_id__put", input)`)
|
|
1342
|
+
- Tier: `destructive`: deletes or archives data; confirm with a human before calling
|
|
1343
|
+
- API-key scope: `team:delete`
|
|
1344
|
+
|
|
1345
|
+
Change someone's role WITHIN this team. Their previous role is gone.
|
|
1346
|
+
|
|
1347
|
+
`cb_team_user_memberships` holds one row per (team, user), so this
|
|
1348
|
+
REPLACES rather than adds. Tiered `destructive` by an explicit rule
|
|
1349
|
+
because it is a privilege change - promoting a colleague to team manager
|
|
1350
|
+
must not be the same grant as renaming the team.
|
|
1351
|
+
|
|
1352
|
+
**Input**
|
|
1353
|
+
|
|
1354
|
+
| Field | Type | Required | Description |
|
|
1355
|
+
|---|---|---|---|
|
|
1356
|
+
| `path.team_id` | `string` | yes | Team id (UUID). |
|
|
1357
|
+
| `path.user_id` | `string` | yes | Identity-provider user id. |
|
|
1358
|
+
| `body` | `TeamMemberRoleUpdateRequest` | yes | Request body; fields below. |
|
|
1359
|
+
|
|
1360
|
+
Body fields (`TeamMemberRoleUpdateRequest`):
|
|
1361
|
+
|
|
1362
|
+
| Field | Type | Required | Description |
|
|
1363
|
+
|---|---|---|---|
|
|
1364
|
+
| `body.team_role` | `string` | yes | max length 20 |
|
|
1365
|
+
|
|
1366
|
+
**Returns** `ApiResponse_OrgPayload_`: the envelope `{ data: OrgPayload, ... }`. `g8.api` returns the envelope as-is, so read `result.data`.
|
|
1367
|
+
|
|
1368
|
+
Other envelope fields: `pagination` (PaginationMeta).
|
|
1369
|
+
|
|
1370
|
+
**Example**
|
|
1371
|
+
|
|
1372
|
+
```ts
|
|
1373
|
+
// destructive: deletes or archives data; confirm with a human before calling.
|
|
1374
|
+
const result = await g8.api.teams.updateTeamMemberRole({
|
|
1375
|
+
path: { team_id: "id", user_id: "id" },
|
|
1376
|
+
body: { team_role: "example" },
|
|
1377
|
+
});
|
|
1378
|
+
```
|
|
1379
|
+
|
|
1380
|
+
---
|
|
1381
|
+
|
|
1382
|
+
## Referenced types
|
|
1383
|
+
|
|
1384
|
+
Named types that appear in the tables above. Full TypeScript definitions: `G8Contract.<Name>` (`import type { G8Contract } from "@graph8/sdk"`).
|
|
1385
|
+
|
|
1386
|
+
<a id="type-workspacememberinput"></a>
|
|
1387
|
+
|
|
1388
|
+
### `WorkspaceMemberInput`
|
|
1389
|
+
|
|
1390
|
+
One member in a team's single-save membership list.
|
|
1391
|
+
|
|
1392
|
+
| Field | Type | Required | Description |
|
|
1393
|
+
|---|---|---|---|
|
|
1394
|
+
| `user_id` | `string` | yes | min length 1, max length 255 |
|
|
1395
|
+
| `role` | `"member" \| "manager"` | no | member \| manager default `"member"` |
|