@nangohq/types 0.71.12 → 0.71.13
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/dist/account/acquisition.d.ts +10 -0
- package/dist/account/api.d.ts +3 -0
- package/dist/agent/api.d.ts +11 -9
- package/dist/agent/playground.api.d.ts +10 -1
- package/dist/agent/toolset.d.ts +9 -0
- package/dist/api.endpoints.d.ts +2 -2
- package/dist/audit-trail/event.d.ts +4 -1
- package/dist/audit-trail/metadata.d.ts +8 -0
- package/dist/billing/types.d.ts +3 -1
- package/dist/flow/http.api.d.ts +1 -1
- package/dist/function/config.d.ts +1 -0
- package/dist/function/db.d.ts +2 -1
- package/dist/functions/api.d.ts +72 -1
- package/dist/index.d.ts +2 -0
- package/dist/internal-auth.d.ts +5 -0
- package/dist/meta/api.d.ts +4 -1
- package/dist/plans/db.d.ts +2 -0
- package/dist/plans/http.api.d.ts +4 -1
- package/dist/providers/provider.d.ts +3 -0
- package/dist/web/env.d.ts +1 -0
- package/dist/webhooks/dispatch.d.ts +1 -2
- package/package.json +1 -1
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** First observed website source. No user identity or full URLs. */
|
|
2
|
+
export interface SignupAcquisition {
|
|
3
|
+
acquisition_utm_source?: string | undefined;
|
|
4
|
+
acquisition_utm_medium?: string | undefined;
|
|
5
|
+
acquisition_utm_campaign?: string | undefined;
|
|
6
|
+
acquisition_utm_content?: string | undefined;
|
|
7
|
+
acquisition_utm_term?: string | undefined;
|
|
8
|
+
acquisition_referring_domain?: string | undefined;
|
|
9
|
+
acquisition_landing_path?: string | undefined;
|
|
10
|
+
}
|
package/dist/account/api.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ import type { ApiEndpoint, ApiError } from '../api.js';
|
|
|
3
3
|
import type { AuditPolicy } from '../audit-trail/event.js';
|
|
4
4
|
import type { MFACredential } from '../mfa/credential.js';
|
|
5
5
|
import type { ApiUser } from '../user/api.js';
|
|
6
|
+
import type { SignupAcquisition } from './acquisition.js';
|
|
6
7
|
export interface AccountApiKey {
|
|
7
8
|
id: number;
|
|
8
9
|
uuid: string;
|
|
@@ -57,6 +58,7 @@ export type PostSignup = ApiEndpoint<{
|
|
|
57
58
|
password: string;
|
|
58
59
|
token?: string | undefined;
|
|
59
60
|
foundUs?: string | undefined;
|
|
61
|
+
acquisition?: SignupAcquisition | undefined;
|
|
60
62
|
};
|
|
61
63
|
Error: ApiError<'email_already_verified'> | ApiError<'error_creating_user'> | ApiError<'user_already_exists'> | ApiError<'error_creating_account'> | ApiError<'not_found'> | ApiError<'email_not_verified'>;
|
|
62
64
|
Success: {
|
|
@@ -206,6 +208,7 @@ export type PostManagedSignup = ApiEndpoint<{
|
|
|
206
208
|
Path: '/api/v1/account/managed/signup';
|
|
207
209
|
Body: {
|
|
208
210
|
provider: 'GoogleOAuth';
|
|
211
|
+
acquisition?: SignupAcquisition | undefined;
|
|
209
212
|
token?: string | undefined;
|
|
210
213
|
returnTo?: string | undefined;
|
|
211
214
|
};
|
package/dist/agent/api.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ import type { AuditPolicy } from '../audit-trail/event.js';
|
|
|
3
3
|
import type { Tags } from '../db.js';
|
|
4
4
|
import type { AgentSessionUnknownPinnedConnectionsPayload } from './connections.js';
|
|
5
5
|
import type { AgentSessionCreateConnectionConfig, AgentSessionEndedReason } from './session.js';
|
|
6
|
-
import type { AgentSessionToolsNotInToolsetPayload, AgentSessionUnknownIntegrationsPayload, AgentSessionUnknownToolsPayload, AgentSessionUnsupportedFunctionTypesPayload } from './toolset.js';
|
|
6
|
+
import type { AgentSessionMcpServerStatus, AgentSessionToolsNotInToolsetPayload, AgentSessionUnknownIntegrationsPayload, AgentSessionUnknownToolsPayload, AgentSessionUnsupportedFunctionTypesPayload } from './toolset.js';
|
|
7
7
|
export interface AgentSessionToolListInput {
|
|
8
8
|
tools: string[];
|
|
9
9
|
}
|
|
@@ -51,6 +51,7 @@ export interface AgentSessionToolsetSummary {
|
|
|
51
51
|
connected: boolean;
|
|
52
52
|
tools_pinned: number;
|
|
53
53
|
tools_searchable: number;
|
|
54
|
+
mcp_server?: AgentSessionMcpServerStatus;
|
|
54
55
|
}
|
|
55
56
|
export interface AgentSessionMetaToolsSummary {
|
|
56
57
|
nango_tool_search: boolean;
|
|
@@ -89,6 +90,14 @@ export type AgentSessionCreationErrorCode = 'ambiguous_connections' | 'unknown_p
|
|
|
89
90
|
*/
|
|
90
91
|
export type AgentSessionCreationErrorPayload = AgentSessionAmbiguousConnectionsReply | AgentSessionUnknownPinnedConnectionsPayload | AgentSessionPinnedConnectionNotMatchedReply | AgentSessionUnknownIntegrationsPayload | AgentSessionUnknownToolsPayload | AgentSessionUnsupportedFunctionTypesPayload | AgentSessionToolsNotInToolsetPayload | AgentSessionUnknownMetaToolsPayload;
|
|
91
92
|
export type PostAgentSessionsCreationError = ApiError<AgentSessionCreationErrorCode, undefined, AgentSessionCreationErrorPayload>;
|
|
93
|
+
export interface ApiCreatedAgentSession {
|
|
94
|
+
session_id: string;
|
|
95
|
+
session_token: string;
|
|
96
|
+
mcp_url: string;
|
|
97
|
+
expires_at: string;
|
|
98
|
+
toolset: Record<string, AgentSessionToolsetSummary>;
|
|
99
|
+
meta_tools: AgentSessionMetaToolsSummary;
|
|
100
|
+
}
|
|
92
101
|
export type PostAgentSessions = ApiEndpoint<{
|
|
93
102
|
Audit: AuditPolicy<'agent_session', 'created', 'environment'>;
|
|
94
103
|
Method: 'POST';
|
|
@@ -96,14 +105,7 @@ export type PostAgentSessions = ApiEndpoint<{
|
|
|
96
105
|
Body: PostAgentSessionsBody;
|
|
97
106
|
Error: PostAgentSessionsCreationError;
|
|
98
107
|
Success: {
|
|
99
|
-
data:
|
|
100
|
-
session_id: string;
|
|
101
|
-
session_token: string;
|
|
102
|
-
mcp_url: string;
|
|
103
|
-
expires_at: string;
|
|
104
|
-
toolset: Record<string, AgentSessionToolsetSummary>;
|
|
105
|
-
meta_tools: AgentSessionMetaToolsSummary;
|
|
106
|
-
};
|
|
108
|
+
data: ApiCreatedAgentSession;
|
|
107
109
|
};
|
|
108
110
|
}>;
|
|
109
111
|
export interface ApiTerminatedAgentSession {
|
|
@@ -3,12 +3,21 @@ export interface AgentPlaygroundUsage {
|
|
|
3
3
|
inputTokens: number;
|
|
4
4
|
outputTokens: number;
|
|
5
5
|
}
|
|
6
|
+
export interface AgentPlaygroundIntegrationSetup {
|
|
7
|
+
provider: string;
|
|
8
|
+
integrationId?: string;
|
|
9
|
+
outcome: 'created' | 'existing' | 'missing_credentials' | 'not_created';
|
|
10
|
+
}
|
|
6
11
|
export interface AgentPlaygroundMessageMetadata {
|
|
7
12
|
sessionId?: string;
|
|
13
|
+
sessionExpiresAt?: string;
|
|
8
14
|
hidden?: boolean;
|
|
15
|
+
connectedIntegrations?: string[];
|
|
16
|
+
starterProvider?: string;
|
|
17
|
+
integrationSetup?: AgentPlaygroundIntegrationSetup;
|
|
9
18
|
usage?: AgentPlaygroundUsage;
|
|
10
19
|
}
|
|
11
|
-
export type AgentPlaygroundErrorCode = 'feature_disabled' | 'session_creation_failed' | 'model_error';
|
|
20
|
+
export type AgentPlaygroundErrorCode = 'feature_disabled' | 'session_creation_failed' | 'model_error' | 'too_many_request';
|
|
12
21
|
export type PostAgentPlaygroundChat = ApiEndpoint<{
|
|
13
22
|
Audit: {
|
|
14
23
|
kind: 'no-audit';
|
package/dist/agent/toolset.d.ts
CHANGED
|
@@ -8,14 +8,23 @@ export interface AgentSessionIntegrationPolicy {
|
|
|
8
8
|
}
|
|
9
9
|
export type AgentSessionToolsetPolicy = '*' | Readonly<Record<string, AgentSessionIntegrationPolicy>>;
|
|
10
10
|
export type AgentSessionPinnedTools = Readonly<Record<string, readonly string[]>>;
|
|
11
|
+
/** A tool the integration's MCP server listed when the session was created, as opposed to a deployed action. */
|
|
12
|
+
export interface AgentSessionMcpToolDefinition {
|
|
13
|
+
readonly inputSchema: Record<string, unknown>;
|
|
14
|
+
readonly annotations?: Record<string, unknown>;
|
|
15
|
+
}
|
|
11
16
|
export interface AgentSessionCompiledTool {
|
|
12
17
|
readonly name: string;
|
|
13
18
|
readonly description: string;
|
|
19
|
+
readonly mcp?: AgentSessionMcpToolDefinition;
|
|
14
20
|
}
|
|
21
|
+
/** `unavailable` means the MCP server could not be listed, so the session carries none of its tools. */
|
|
22
|
+
export type AgentSessionMcpServerStatus = 'available' | 'unavailable';
|
|
15
23
|
export interface AgentSessionCompiledIntegration {
|
|
16
24
|
readonly provider: string;
|
|
17
25
|
readonly pinned: AgentSessionCompiledTool[];
|
|
18
26
|
readonly searchable: AgentSessionCompiledTool[];
|
|
27
|
+
readonly mcpServer?: AgentSessionMcpServerStatus;
|
|
19
28
|
}
|
|
20
29
|
export type AgentSessionCompiledToolset = Record<string, AgentSessionCompiledIntegration>;
|
|
21
30
|
export interface AgentSessionToolNames {
|
package/dist/api.endpoints.d.ts
CHANGED
|
@@ -18,7 +18,7 @@ import type { CreateApiKey, DeleteApiKey, DeleteEnvironment, DeletePublicApiKey,
|
|
|
18
18
|
import type { PatchWebhook } from './environment/api/webhook.js';
|
|
19
19
|
import type { PostEnvironmentVariables } from './environment/variable/api.js';
|
|
20
20
|
import type { PatchFlowDisable, PatchFlowEnable, PatchFlowFrequency, PostPreBuiltDeploy, PutUpgradePreBuiltFlow } from './flow/http.api.js';
|
|
21
|
-
import type { DeleteIntegrationFunction, DeletePublicIntegrationFunction, GetFunction, GetFunctionDeployment, GetFunctionDryrun, GetFunctionInvocation, GetFunctions, GetIntegrationFunction, GetIntegrationFunctions, GetIntegrationTemplates, GetProviderTemplates, GetPublicIntegrationFunction, GetPublicIntegrationFunctions, GetPublicProviderTemplates, PatchFunction, PostFunctionCompile, PostFunctionDeployment, PostFunctionDeploymentBundle, PostFunctionDeploymentBundlePreview, PostFunctionDeploymentResult, PostFunctionDryrun, PostFunctionDryrunResult, PostFunctionInvocation } from './functions/api.js';
|
|
21
|
+
import type { DeleteFunctionVariant, DeleteIntegrationFunction, DeletePublicIntegrationFunction, GetFunction, GetFunctionDeployment, GetFunctionDryrun, GetFunctionInvocation, GetFunctions, GetIntegrationFunction, GetIntegrationFunctions, GetIntegrationTemplates, GetProviderTemplates, GetPublicIntegrationFunction, GetPublicIntegrationFunctions, GetPublicProviderTemplates, PatchConnectionFunction, PatchFunction, PatchFunctionVariant, PostFunctionCompile, PostFunctionDeployment, PostFunctionDeploymentBundle, PostFunctionDeploymentBundlePreview, PostFunctionDeploymentResult, PostFunctionDryrun, PostFunctionDryrunResult, PostFunctionInvocation, PostFunctionVariant } from './functions/api.js';
|
|
22
22
|
import type { GetGettingStarted, PatchGettingStarted } from './gettingStarted/api.js';
|
|
23
23
|
import type { DeleteIntegration, DeletePublicIntegration, GetFunctionCode, GetIntegration, GetIntegrationFlows, GetPublicFunctionCode, GetPublicIntegration, GetPublicListIntegrations, PatchIntegration, PatchPublicIntegration, PostIntegration, PostPublicIntegration, PostPublicQuickstartIntegration } from './integration/api.js';
|
|
24
24
|
import type { DeleteInvite, GetInvite, PostInvite } from './invitations/api.js';
|
|
@@ -36,7 +36,7 @@ import type { GetConnectionSyncs, GetPublicSyncStatus, PostPublicSyncPause, Post
|
|
|
36
36
|
import type { DeleteTeamUser, GetTeam, PatchTeamUser, PutTeam } from './team/api.js';
|
|
37
37
|
import type { GetUser, PatchUser, PutUserPassword } from './user/api.js';
|
|
38
38
|
import type { PostPublicWebhook } from './webhooks/http.api.js';
|
|
39
|
-
export type PublicApiEndpoints = SetMetadata | UpdateMetadata | PostDeploy | PostDeployConfirmation | PostPublicTrigger | PostPublicTbaAuthorization | PostPublicJwtAuthorization | PostPublicUnauthenticatedAuthorization | PostPublicApiKeyAuthorization | PostPublicBasicAuthorization | GetPublicProviders | GetPublicProvider | GetPublicListIntegrations | GetPublicIntegration | DeletePublicIntegration | PostConnectSessions | PostAgentSessions | DeleteAgentSession | PostAgentSessionMcp | GetAgentSessionMcp | PostPublicConnectSessionsReconnect | GetPublicConnections | GetPublicConnection | GetConnectSession | DeleteConnectSession | PostDeployInternal | PostPublicBillAuthorization | DeletePublicConnection | DeleteConnection | PostPublicSignatureAuthorization | PostPublicTwoStepAuthorization | PostPublicWebhook | GetPublicClientMetadata | GetPublicRecords | PatchPublicPruneRecords | GetPublicScriptsConfig | PostPublicConnectTelemetry | PostCliTelemetry | PutPublicSyncConnectionFrequency | PostPublicIntegration | PostPublicQuickstartIntegration | PatchPublicIntegration | GetAsyncActionResult | PostPublicOauthOutboundAuthorization | PostPublicAwsSigV4Authorization | PostPublicConnection | PatchPublicConnection | PostPublicSyncStart | PostPublicSyncPause | GetPublicSyncStatus | GetPublicV1 | PostPublicTriggerAction | PostFunctionCompile | GetFunction | GetFunctions | PatchFunction | PostFunctionDryrun | GetFunctionDryrun | PostFunctionDryrunResult | PostFunctionDeployment | GetFunctionDeployment | PostFunctionDeploymentResult | PostFunctionInvocation | GetFunctionInvocation | PostFunctionDeploymentBundle | PostFunctionDeploymentBundlePreview | GetPublicFunctionCode | GetPublicIntegrationFunctions | GetPublicIntegrationFunction | DeletePublicIntegrationFunction | GetPublicProviderTemplates | PostPublicRotateWebhookSigningKey | AllPublicProxy | PostPublicEnvironment | DeletePublicEnvironment | GetPublicEnvironments | GetPublicApiKey | GetPublicApiKeys | PostPublicApiKey | DeletePublicApiKey;
|
|
39
|
+
export type PublicApiEndpoints = SetMetadata | UpdateMetadata | PostDeploy | PostDeployConfirmation | PostPublicTrigger | PostPublicTbaAuthorization | PostPublicJwtAuthorization | PostPublicUnauthenticatedAuthorization | PostPublicApiKeyAuthorization | PostPublicBasicAuthorization | GetPublicProviders | GetPublicProvider | GetPublicListIntegrations | GetPublicIntegration | DeletePublicIntegration | PostConnectSessions | PostAgentSessions | DeleteAgentSession | PostAgentSessionMcp | GetAgentSessionMcp | PostPublicConnectSessionsReconnect | GetPublicConnections | GetPublicConnection | GetConnectSession | DeleteConnectSession | PostDeployInternal | PostPublicBillAuthorization | DeletePublicConnection | DeleteConnection | PostPublicSignatureAuthorization | PostPublicTwoStepAuthorization | PostPublicWebhook | GetPublicClientMetadata | GetPublicRecords | PatchPublicPruneRecords | GetPublicScriptsConfig | PostPublicConnectTelemetry | PostCliTelemetry | PutPublicSyncConnectionFrequency | PostPublicIntegration | PostPublicQuickstartIntegration | PatchPublicIntegration | GetAsyncActionResult | PostPublicOauthOutboundAuthorization | PostPublicAwsSigV4Authorization | PostPublicConnection | PatchPublicConnection | PostPublicSyncStart | PostPublicSyncPause | GetPublicSyncStatus | GetPublicV1 | PostPublicTriggerAction | PostFunctionCompile | GetFunction | GetFunctions | PatchFunction | PostFunctionDryrun | GetFunctionDryrun | PostFunctionDryrunResult | PostFunctionDeployment | GetFunctionDeployment | PostFunctionDeploymentResult | PostFunctionInvocation | PostFunctionVariant | PatchFunctionVariant | PatchConnectionFunction | DeleteFunctionVariant | GetFunctionInvocation | PostFunctionDeploymentBundle | PostFunctionDeploymentBundlePreview | GetPublicFunctionCode | GetPublicIntegrationFunctions | GetPublicIntegrationFunction | DeletePublicIntegrationFunction | GetPublicProviderTemplates | PostPublicRotateWebhookSigningKey | AllPublicProxy | PostPublicEnvironment | DeletePublicEnvironment | GetPublicEnvironments | GetPublicApiKey | GetPublicApiKeys | PostPublicApiKey | DeletePublicApiKey;
|
|
40
40
|
export type PrivateApiEndpoints = GetAuditTrail | GetAuditTrailExport | ListAccountApiKeys | CreateAccountApiKey | DeleteAccountApiKey | ConfirmEmail | PostSignup | PostSignin | PostLogout | GetTeam | PutTeam | PostPlanExtendTrial | PostPlanChange | PutBillingInvoicingDetails | GetOverdueInvoices | GetBillingUsage | GetBillingUsageTopDimensionValues | GetUpcomingInvoice | GetBillingPeriodCosts | GetProjectedCosts | GetSpendAlert | PutSpendAlert | DeleteSpendAlert | GetUser | PatchUser | PutUserPassword | PostInvite | DeleteInvite | DeleteTeamUser | PatchTeamUser | PostInsights | PostForgotPassword | PutResetPassword | SearchOperations | GetOperation | SearchMessages | SearchFilters | PostInternalConnectSessions | GetIntegrationFlows | GetIntegrationFunction | GetIntegrationFunctions | GetFunctionCode | DeleteIntegrationFunction | GetIntegrationTemplates | GetProviderTemplates | DeleteIntegration | PatchIntegration | GetIntegration | PostIntegration | GetConnections | GetConnectionsCount | GetConnection | PatchConnection | PostConnectionMetadata | GetConnectionRecordModels | GetConnectionRecords | GetConnectionSyncs | GetInvite | GetMeta | GetEmailByExpiredToken | GetEmailByUuid | GetManagedCallback | GetManagedEmailVerification | GetOnboardingAccountDiscovery | PostOnboardingRequestInvite | PatchFlowDisable | PatchFlowEnable | PatchFlowFrequency | PutUpgradePreBuiltFlow | PostConnectionRefresh | PostManagedEmailVerification | PostManagedSignup | PostPreBuiltDeploy | PostEnvironment | PatchEnvironment | DeleteEnvironment | GetEnvironments | GetEnvironment | PostRotateWebhookSigningKey | ListApiKeys | CreateApiKey | DeleteApiKey | PatchApiKey | PatchWebhook | PostEnvironmentVariables | PostImpersonate | GetSharedCredentialsProviders | GetSharedCredentialsProvider | PostSharedCredentialsProvider | PatchSharedCredentialsProvider | GetGettingStarted | PatchGettingStarted | GetConnectUISettings | PutConnectUISettings | GetProviders | GetProvider | PostInternalTriggerFunction | GetMFAStatus | PostMFAEnrollment | PostMFAActivation | PostMFARecoveryCodes | PostMFALoginVerification | DeleteMFA | GetPlainHmac | PostAgentPlaygroundChat;
|
|
41
41
|
export type APIEndpoints = PrivateApiEndpoints | PublicApiEndpoints;
|
|
42
42
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { AgentSessionCreatedMetadata, ApiKeyUpdatedMetadata, AppAuthLoginMetadata, AuditTrailFiltersMetadata, AuditTrailQueriedMetadata, BillingPaymentMethodRemovedMetadata, BillingPlanChangedMetadata, BillingSpendAlertChangedMetadata, ConnectionMetadata, ConnectionUpdatedMetadata, EnvironmentCreatedMetadata, EnvironmentUpdatedMetadata, EnvironmentVariablesChangedMetadata, EnvironmentWebhookMetadata, FunctionDeletedMetadata, FunctionDeployedMetadata, FunctionUpdatedMetadata, FunctionUpgradedMetadata, IntegrationProviderMetadata, IntegrationUpdatedMetadata, MemberInvitedMetadata, MemberRoleChangedMetadata, MfaVerifiedMetadata, SyncBaseMetadata, SyncFrequencyChangedMetadata, SyncTriggeredMetadata, SyncVariantMetadata, TeamUpdatedMetadata, UserUpdatedMetadata } from './metadata.js';
|
|
1
|
+
import type { AgentSessionCreatedMetadata, ApiKeyUpdatedMetadata, AppAuthLoginMetadata, AuditTrailFiltersMetadata, AuditTrailQueriedMetadata, BillingPaymentMethodRemovedMetadata, BillingPlanChangedMetadata, BillingSpendAlertChangedMetadata, ConnectionMetadata, ConnectionUpdatedMetadata, EnvironmentCreatedMetadata, EnvironmentUpdatedMetadata, EnvironmentVariablesChangedMetadata, EnvironmentWebhookMetadata, FunctionDeletedMetadata, FunctionDeployedMetadata, FunctionUpdatedMetadata, FunctionUpgradedMetadata, FunctionVariantMetadata, FunctionVariantSettingsMetadata, IntegrationProviderMetadata, IntegrationUpdatedMetadata, MemberInvitedMetadata, MemberRoleChangedMetadata, MfaVerifiedMetadata, SyncBaseMetadata, SyncFrequencyChangedMetadata, SyncTriggeredMetadata, SyncVariantMetadata, TeamUpdatedMetadata, UserUpdatedMetadata } from './metadata.js';
|
|
2
2
|
export type AuditTrailVersion = '2026-07-16';
|
|
3
3
|
export type AuditActorType = 'user' | 'api_key' | 'public_key' | 'connect_session' | 'anonymous' | 'unknown';
|
|
4
4
|
export type AuditOutcome = 'success' | 'failure' | 'denied';
|
|
@@ -28,6 +28,9 @@ interface AuditEventTable {
|
|
|
28
28
|
upgraded: FunctionUpgradedMetadata;
|
|
29
29
|
updated: FunctionUpdatedMetadata;
|
|
30
30
|
deleted: FunctionDeletedMetadata;
|
|
31
|
+
variant_created: FunctionVariantMetadata;
|
|
32
|
+
variant_deleted: FunctionVariantMetadata;
|
|
33
|
+
variant_updated: FunctionVariantSettingsMetadata;
|
|
31
34
|
};
|
|
32
35
|
integration: {
|
|
33
36
|
created: IntegrationProviderMetadata;
|
|
@@ -54,6 +54,14 @@ export interface SyncFrequencyChangedMetadata extends SyncBaseMetadata {
|
|
|
54
54
|
export interface SyncVariantMetadata extends SyncBaseMetadata {
|
|
55
55
|
variant?: string;
|
|
56
56
|
}
|
|
57
|
+
export interface FunctionVariantMetadata {
|
|
58
|
+
connectionId?: string;
|
|
59
|
+
variant?: string;
|
|
60
|
+
}
|
|
61
|
+
export interface FunctionVariantSettingsMetadata extends FunctionVariantMetadata {
|
|
62
|
+
enabled?: boolean;
|
|
63
|
+
frequency?: string | null;
|
|
64
|
+
}
|
|
57
65
|
export interface SyncTriggeredMetadata extends SyncBaseMetadata {
|
|
58
66
|
reset?: boolean;
|
|
59
67
|
emptyCache?: boolean;
|
package/dist/billing/types.d.ts
CHANGED
|
@@ -24,7 +24,9 @@ export interface BillingClient {
|
|
|
24
24
|
pendingChangeId: string;
|
|
25
25
|
amountInCents: number | null;
|
|
26
26
|
}>>;
|
|
27
|
-
downgrade: (opts: PlanChangeRequest) => Promise<Result<
|
|
27
|
+
downgrade: (opts: PlanChangeRequest) => Promise<Result<{
|
|
28
|
+
changeAt: Date | null;
|
|
29
|
+
}>>;
|
|
28
30
|
startGrowthAddon: (opts: {
|
|
29
31
|
subscriptionId: string;
|
|
30
32
|
}) => Promise<Result<{
|
package/dist/flow/http.api.d.ts
CHANGED
|
@@ -80,7 +80,7 @@ export type PatchFlowDisable = ApiEndpoint<{
|
|
|
80
80
|
scriptName: string;
|
|
81
81
|
type: ScriptTypeLiteral;
|
|
82
82
|
};
|
|
83
|
-
Error: ApiError<'unknown_provider'>;
|
|
83
|
+
Error: ApiError<'unknown_provider'> | ApiError<'unknown_sync_config'>;
|
|
84
84
|
Success: {
|
|
85
85
|
data: {
|
|
86
86
|
success: boolean;
|
package/dist/function/db.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { TimestampsAndDeletedAt } from '../db.js';
|
|
2
2
|
import type { FunctionSource } from '../syncConfigs/db.js';
|
|
3
|
-
import type { FunctionCapabilities, FunctionLimits, FunctionRequires, FunctionTriggerDefinition } from './config.js';
|
|
3
|
+
import type { FunctionCapabilities, FunctionLimits, FunctionRequires, FunctionTags, FunctionTriggerDefinition } from './config.js';
|
|
4
4
|
import type { JSONSchema7 } from 'json-schema';
|
|
5
5
|
export interface DBFunctionConfig extends TimestampsAndDeletedAt {
|
|
6
6
|
id: number;
|
|
@@ -15,6 +15,7 @@ export interface DBFunctionConfigVersion extends TimestampsAndDeletedAt {
|
|
|
15
15
|
id: number;
|
|
16
16
|
function_config_id: number;
|
|
17
17
|
description: string;
|
|
18
|
+
tags: FunctionTags;
|
|
18
19
|
file_location: string;
|
|
19
20
|
version: string;
|
|
20
21
|
source: FunctionSource;
|
package/dist/functions/api.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ApiEndpoint, ApiError } from '../api.js';
|
|
2
2
|
import type { AuditPolicy } from '../audit-trail/event.js';
|
|
3
|
-
import type { FunctionCapabilities, FunctionLimits, FunctionRequires, FunctionTriggerDefinition } from '../function/config.js';
|
|
3
|
+
import type { FunctionCapabilities, FunctionLimits, FunctionRequires, FunctionTags, FunctionTriggerDefinition } from '../function/config.js';
|
|
4
4
|
import type { FunctionSource } from '../syncConfigs/db.js';
|
|
5
5
|
import type { FunctionType, ListedNangoFunction, NangoActionFunction, NangoFunctionTemplate, NangoSyncFunction } from './domain.js';
|
|
6
6
|
import type { JSONSchema7 } from 'json-schema';
|
|
@@ -229,6 +229,7 @@ export interface GetFunctionResponse {
|
|
|
229
229
|
provider: string;
|
|
230
230
|
name: string;
|
|
231
231
|
description: string;
|
|
232
|
+
tags: FunctionTags;
|
|
232
233
|
state: 'enabled' | 'disabled';
|
|
233
234
|
source: FunctionSource;
|
|
234
235
|
trigger: FunctionTriggerDefinition;
|
|
@@ -301,6 +302,75 @@ export type PostFunctionInvocation = ApiEndpoint<{
|
|
|
301
302
|
Error: ApiError<FunctionInvocationErrorCode>;
|
|
302
303
|
Success: FunctionInvocationSuccess;
|
|
303
304
|
}>;
|
|
305
|
+
export type FunctionVariantErrorCode = 'invalid_variant' | 'function_not_found' | 'connection_not_found' | 'function_disabled' | 'function_variant_not_found' | 'invalid_frequency' | 'resource_capped' | 'server_error';
|
|
306
|
+
export type FunctionVariantSuccess = {
|
|
307
|
+
function: {
|
|
308
|
+
uuid: string;
|
|
309
|
+
name: string;
|
|
310
|
+
};
|
|
311
|
+
variant: string;
|
|
312
|
+
frequency: string;
|
|
313
|
+
state: 'enabled' | 'disabled';
|
|
314
|
+
};
|
|
315
|
+
export type PostFunctionVariant = ApiEndpoint<{
|
|
316
|
+
Audit: AuditPolicy<'function', 'variant_created', 'environment'>;
|
|
317
|
+
Method: 'POST';
|
|
318
|
+
Path: '/connections/:connectionId/functions/:functionUuid/variants';
|
|
319
|
+
Params: {
|
|
320
|
+
connectionId: string;
|
|
321
|
+
functionUuid: string;
|
|
322
|
+
};
|
|
323
|
+
Body: {
|
|
324
|
+
variant: string;
|
|
325
|
+
};
|
|
326
|
+
Error: ApiError<FunctionVariantErrorCode>;
|
|
327
|
+
Success: FunctionVariantSuccess;
|
|
328
|
+
}>;
|
|
329
|
+
export type DeleteFunctionVariant = ApiEndpoint<{
|
|
330
|
+
Audit: AuditPolicy<'function', 'variant_deleted', 'environment'>;
|
|
331
|
+
Method: 'DELETE';
|
|
332
|
+
Path: '/connections/:connectionId/functions/:functionUuid/variants/:variant';
|
|
333
|
+
Params: {
|
|
334
|
+
connectionId: string;
|
|
335
|
+
functionUuid: string;
|
|
336
|
+
variant: string;
|
|
337
|
+
};
|
|
338
|
+
Error: ApiError<FunctionVariantErrorCode>;
|
|
339
|
+
Success: {
|
|
340
|
+
success: boolean;
|
|
341
|
+
};
|
|
342
|
+
}>;
|
|
343
|
+
export type PatchConnectionFunction = ApiEndpoint<{
|
|
344
|
+
Audit: AuditPolicy<'function', 'variant_updated', 'environment'>;
|
|
345
|
+
Method: 'PATCH';
|
|
346
|
+
Path: '/connections/:connectionId/functions/:functionUuid';
|
|
347
|
+
Params: {
|
|
348
|
+
connectionId: string;
|
|
349
|
+
functionUuid: string;
|
|
350
|
+
};
|
|
351
|
+
Body: PatchFunctionVariant['Body'];
|
|
352
|
+
Error: ApiError<FunctionVariantErrorCode>;
|
|
353
|
+
Success: FunctionVariantSuccess;
|
|
354
|
+
}>;
|
|
355
|
+
export type PatchFunctionVariant = ApiEndpoint<{
|
|
356
|
+
Audit: AuditPolicy<'function', 'variant_updated', 'environment'>;
|
|
357
|
+
Method: 'PATCH';
|
|
358
|
+
Path: '/connections/:connectionId/functions/:functionUuid/variants/:variant';
|
|
359
|
+
Params: {
|
|
360
|
+
connectionId: string;
|
|
361
|
+
functionUuid: string;
|
|
362
|
+
variant: string;
|
|
363
|
+
};
|
|
364
|
+
Body: {
|
|
365
|
+
enabled: boolean;
|
|
366
|
+
frequency?: string | null;
|
|
367
|
+
} | {
|
|
368
|
+
enabled?: boolean;
|
|
369
|
+
frequency: string | null;
|
|
370
|
+
};
|
|
371
|
+
Error: ApiError<FunctionVariantErrorCode>;
|
|
372
|
+
Success: FunctionVariantSuccess;
|
|
373
|
+
}>;
|
|
304
374
|
export type GetFunctionInvocation = ApiEndpoint<{
|
|
305
375
|
Audit: {
|
|
306
376
|
kind: 'no-audit';
|
|
@@ -481,6 +551,7 @@ export interface FunctionDeploymentArtifact {
|
|
|
481
551
|
name: string;
|
|
482
552
|
integrationId: string;
|
|
483
553
|
description: string;
|
|
554
|
+
tags?: FunctionTags | undefined;
|
|
484
555
|
trigger: FunctionTriggerDefinition;
|
|
485
556
|
requires: FunctionRequires;
|
|
486
557
|
capabilities: FunctionCapabilities;
|
package/dist/index.d.ts
CHANGED
|
@@ -21,6 +21,7 @@ export type * from './agent/toolSearch.js';
|
|
|
21
21
|
export type * from './agent/toolset.js';
|
|
22
22
|
export type * from './admin/http.api.js';
|
|
23
23
|
export type * from './account/api.js';
|
|
24
|
+
export type * from './account/acquisition.js';
|
|
24
25
|
export type * from './account/context.js';
|
|
25
26
|
export type * from './user/api.js';
|
|
26
27
|
export type * from './user/db.js';
|
|
@@ -97,6 +98,7 @@ export type * from './utils.js';
|
|
|
97
98
|
export type * from './web/env.js';
|
|
98
99
|
export type * from './fleet/api.js';
|
|
99
100
|
export type * from './fleet/index.js';
|
|
101
|
+
export type * from './internal-auth.js';
|
|
100
102
|
export type * from './persist/api.js';
|
|
101
103
|
export type * from './jobs/api.js';
|
|
102
104
|
export type * from './checkpoint/types.js';
|
package/dist/meta/api.d.ts
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
|
+
import type { SignupAcquisition } from '../account/acquisition.js';
|
|
1
2
|
import type { ApiEndpoint, ApiError } from '../api.js';
|
|
2
3
|
import type { DBEnvironment } from '../environment/db.js';
|
|
3
4
|
export type ApiEnvironmentSummary = Pick<DBEnvironment, 'id' | 'account_id' | 'name' | 'is_production'>;
|
|
4
|
-
export type AccountGroupProperties = {
|
|
5
|
+
export type AccountGroupProperties = SignupAcquisition & {
|
|
5
6
|
name?: string;
|
|
6
7
|
plan?: string;
|
|
7
8
|
created_date?: string;
|
|
8
9
|
is_internal?: boolean;
|
|
10
|
+
discovery_source?: string;
|
|
9
11
|
};
|
|
10
12
|
export type GetMeta = ApiEndpoint<{
|
|
11
13
|
Audit: {
|
|
@@ -26,6 +28,7 @@ export type GetMeta = ApiEndpoint<{
|
|
|
26
28
|
debugMode: boolean;
|
|
27
29
|
gettingStartedClosed: boolean;
|
|
28
30
|
auditTrail: boolean;
|
|
31
|
+
toolsCatalog: boolean;
|
|
29
32
|
accountGroup: AccountGroupProperties;
|
|
30
33
|
agentPlayground: boolean;
|
|
31
34
|
};
|
package/dist/plans/db.d.ts
CHANGED
package/dist/plans/http.api.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ApiEndpoint } from '../api.js';
|
|
1
|
+
import type { ApiEndpoint, ApiError } from '../api.js';
|
|
2
2
|
import type { AuditPolicy } from '../audit-trail/event.js';
|
|
3
3
|
import type { ApiBillingUsageMetrics, BillingCustomer, BillingInvoicingDetails, BreakdownDimensions } from '../billing/types.js';
|
|
4
4
|
import type { MetricUsageSummary, UsageMetric } from '../usage/index.js';
|
|
@@ -248,6 +248,8 @@ export type GetSpendAlert = ApiEndpoint<{
|
|
|
248
248
|
* or no Orb subscription yet; otherwise set even when the threshold is null.
|
|
249
249
|
*/
|
|
250
250
|
currency: string | null;
|
|
251
|
+
/** A threshold has to be above this. Null when the plan gets no spend alerts. */
|
|
252
|
+
floorInCents: number | null;
|
|
251
253
|
};
|
|
252
254
|
};
|
|
253
255
|
}>;
|
|
@@ -261,6 +263,7 @@ export type PutSpendAlert = ApiEndpoint<{
|
|
|
261
263
|
Body: {
|
|
262
264
|
thresholdInCents: number;
|
|
263
265
|
};
|
|
266
|
+
Error: ApiError<'threshold_below_floor'>;
|
|
264
267
|
Success: {
|
|
265
268
|
data: {
|
|
266
269
|
thresholdInCents: number;
|
|
@@ -83,10 +83,12 @@ export interface BaseProvider {
|
|
|
83
83
|
authorization_code_param_in_webhook?: string;
|
|
84
84
|
docs: string;
|
|
85
85
|
docs_connect?: string;
|
|
86
|
+
mcp_endpoint?: string;
|
|
86
87
|
setup_guide_url?: string;
|
|
87
88
|
token_expiration_buffer?: number;
|
|
88
89
|
webhook_routing_script?: string;
|
|
89
90
|
webhook_user_defined_secret?: boolean;
|
|
91
|
+
webhook_signature_enforced?: boolean;
|
|
90
92
|
webhook_allowed_query_params?: string[];
|
|
91
93
|
post_connection_script?: string;
|
|
92
94
|
pre_connection_deletion_script?: string;
|
|
@@ -100,6 +102,7 @@ export interface BaseProvider {
|
|
|
100
102
|
authorization_url_fragment?: string;
|
|
101
103
|
body_format?: OAuthBodyFormatType;
|
|
102
104
|
require_client_certificate?: boolean;
|
|
105
|
+
allow_unverified_https?: boolean;
|
|
103
106
|
token_request_auth_method?: 'basic' | 'custom' | 'private_key_jwt';
|
|
104
107
|
available_scopes?: string[];
|
|
105
108
|
}
|
package/dist/web/env.d.ts
CHANGED
|
@@ -34,10 +34,9 @@ export interface LegacyDispatchMessage extends DispatchMessageBase {
|
|
|
34
34
|
}
|
|
35
35
|
export interface FunctionDispatchMessage extends DispatchMessageBase {
|
|
36
36
|
kind: 'function';
|
|
37
|
-
|
|
37
|
+
functionUuid: string;
|
|
38
38
|
/** Deterministic key used to deduplicate queue redeliveries. */
|
|
39
39
|
idempotencyKey: string;
|
|
40
|
-
functionName: string;
|
|
41
40
|
trigger: Omit<Extract<FunctionTrigger, {
|
|
42
41
|
kind: 'http';
|
|
43
42
|
}>, 'request' | 'connection'> & {
|