@vibiz/sdk 0.3.9 → 0.3.10
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/client.d.ts +8 -6
- package/dist/index.js +1 -1
- package/dist/one-key.d.ts +1 -1
- package/dist/types.d.ts +20 -2
- package/package.json +1 -1
package/dist/client.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ActionInfo, ActionResult, ActionRun, ActionRunList, ActionRunsQuery, ActionUsage, AdminMetrics, AiJob, AiModelInfo, AiProviderKey, AiProviderKeyInput, AiProviderKeyList, AiSettings, AnalyticsPeriod, AnalyticsReport, ApiKey, AppKeyInfo, AppStoreAccount, AppStoreConnectLink, AppStoreSetup, AppStoreSetupInput, AppStoreState, AuthEnvironment, AuthProviderId, AuthProviderInput, AuthSettings, AuthSettingsPatch, Automation, AutomationEnrollment, AutomationInput, AutomationTrigger, Billing, BillingCharge, BillingCheckout, BillingEntry, BillingEntryKind, BillingList, BillingUpdate, Broadcast, BroadcastInput, BroadcastRecipient, BroadcastReview, BroadcastStatus, ChatChunk, ChatCompletion, ChatRequest, Checkout, CheckoutBrandPatch, CheckoutInput, Company, CompanyAddressFields, CompanyCatalog, CompanyDraft, CompanyEnvironment, CompanyLink, Connector, ConnectorApproval, ConnectorCall, ConnectorCallInput, ConnectorCheck, ConnectorEnvironment, ConnectorImport, ConnectorInput, ConnectorPatch, ConnectorResponse, ContactPropertyValue, ContactStatus, DashboardLink, DeployFile, Deployment, DeploymentFiles, DesignSectionRead, DesignSpec, DevEnvironment, DnsRecord, DnsRecordInput, DnsRecordList, Domain, DomainBuyInput, DomainList, DomainOwnerContact, DomainOwnerDetails, DomainQuote, DomainSearch, DomainUse, DomainUseInput, EmailContact, EmailContactInput, EmailContactList, EmailContactPatch, EmailForwarding, EmailForwardingLog, EmailForwardingRule, EmailImportInput, EmailImportReport, EmailList, EmailMarketing, EmailMarketingPatch, EmailPage, EmailPreview, EmailSegment, EmailTestResult, EnvTargetInfo, EnvVarInfo, ExportInput, FileEnvironment, FileList, FileListOptions, FileUploadOptions, HealthList, HealthRun, HealthStatus, HostKind, ImageRequest, ImageResult, InboxSettings, KeyAccess, LedgerEntry, Mailbox, MailboxInput, MailDomain, MailFolder, MailReplyInput, MailSendInput, MailThreadDetail, MailThreadList, MailView, MetricsReport, MissionControl, MissionControlLayout, Operation, OwnAccountLink, OwnedDomain, OwnedDomainList, OwnerStripe, OwnerStripeApply, OwnerStripeDisconnect, OwnerStripeLink, Payment, PaymentPrice, PaymentPriceInput, PaymentProduct, PaymentSubscription, PaymentsAccount, PaymentsEnvironment, PaymentsList, PaymentsSimulation, PhoneAnsweringInput, PhoneCall, PhoneCallInput, PhoneCallList, PhoneMessage, PhoneMessageList, PhoneNumber, PhoneNumberList, PhoneQuote, PhoneRegistrationInput, PhoneRegistrationRequirements, PhoneSearch, PhoneSendInput, PhoneThreadList, Project, ProjectExport, ProjectHealth, ProjectSearch, ReplayDetail, ReplayFrames, ReplayFramesOptions, ReplayInsights, ReplayListOptions, ReplayPeriod, ReplayStatus, ReplaySummary, Resource, ResourceType, SearchConnectionList, SearchPageList, SecretLink, SegmentFilter, SendEmailInput, SendEmailOutput, SocialAccount, SocialAccountAnalytics, SocialAdCampaign, SocialAdChange, SocialAdChangeInput, SocialCampaignCreateInput, SocialConnectLink, SocialEnvironment, SocialMedia, SocialOverview, SocialPost, SocialPostAnalytics, SocialPostInput, SpeechRequest, Transcription, UsageOptions, UsagePeriod, UsageReport, VersionDiff, VersionList, VersionRestore, VibizFile, WebDesignInput, WebhookDelivery, WebhookEventType, Withdrawal } from './types.js';
|
|
1
|
+
import type { ActionInfo, ActionResult, ActionRun, ActionRunList, ActionRunsQuery, ActionUsage, AdminMetrics, AiJob, AiKeyProvider, AiModelInfo, AiProviderKey, AiProviderKeyInput, AiProviderKeyList, AiSettings, AnalyticsPeriod, AnalyticsReport, ApiKey, AppKeyInfo, AppStoreAccount, AppStoreConnectLink, AppStoreSetup, AppStoreSetupInput, AppStoreState, AuthEnvironment, AuthProviderId, AuthProviderInput, AuthSettings, AuthSettingsPatch, Automation, AutomationEnrollment, AutomationInput, AutomationTrigger, Billing, BillingCharge, BillingCheckout, BillingEntry, BillingEntryKind, BillingList, BillingUpdate, Broadcast, BroadcastInput, BroadcastRecipient, BroadcastReview, BroadcastStatus, ChatChunk, ChatCompletion, ChatRequest, Checkout, CheckoutBrandPatch, CheckoutInput, Company, CompanyAddressFields, CompanyCatalog, CompanyDraft, CompanyEnvironment, CompanyLink, Connector, ConnectorApproval, ConnectorCall, ConnectorCallInput, ConnectorCheck, ConnectorEnvironment, ConnectorImport, ConnectorInput, ConnectorPatch, ConnectorResponse, ContactPropertyValue, ContactStatus, DashboardLink, DeployFile, Deployment, DeploymentFiles, DesignSectionRead, DesignSpec, DevEnvironment, DnsRecord, DnsRecordInput, DnsRecordList, Domain, DomainBuyInput, DomainList, DomainOwnerContact, DomainOwnerDetails, DomainQuote, DomainSearch, DomainUse, DomainUseInput, EmailContact, EmailContactInput, EmailContactList, EmailContactPatch, EmailForwarding, EmailForwardingLog, EmailForwardingRule, EmailImportInput, EmailImportReport, EmailList, EmailMarketing, EmailMarketingPatch, EmailPage, EmailPreview, EmailSegment, EmailTestResult, EnvTargetInfo, EnvVarInfo, ExportInput, FileEnvironment, FileList, FileListOptions, FileUploadOptions, HealthList, HealthRun, HealthStatus, HostKind, ImageRequest, ImageResult, InboxSettings, KeyAccess, LedgerEntry, Mailbox, MailboxInput, MailDomain, MailFolder, MailReplyInput, MailSendInput, MailThreadDetail, MailThreadList, MailView, MetricsReport, MissionControl, MissionControlLayout, Operation, OwnAccountLink, OwnedDomain, OwnedDomainList, OwnerStripe, OwnerStripeApply, OwnerStripeDisconnect, OwnerStripeLink, Payment, PaymentPrice, PaymentPriceInput, PaymentProduct, PaymentSubscription, PaymentsAccount, PaymentsEnvironment, PaymentsList, PaymentsSimulation, PhoneAnsweringInput, PhoneCall, PhoneCallInput, PhoneCallList, PhoneMessage, PhoneMessageList, PhoneNumber, PhoneNumberList, PhoneQuote, PhoneRegistrationInput, PhoneRegistrationRequirements, PhoneSearch, PhoneSendInput, PhoneThreadList, Project, ProjectExport, ProjectHealth, ProjectSearch, ReplayDetail, ReplayFrames, ReplayFramesOptions, ReplayInsights, ReplayListOptions, ReplayPeriod, ReplayStatus, ReplaySummary, Resource, ResourceType, SearchConnectionList, SearchPageList, SecretLink, SegmentFilter, SendEmailInput, SendEmailOutput, SocialAccount, SocialAccountAnalytics, SocialAdCampaign, SocialAdChange, SocialAdChangeInput, SocialCampaignCreateInput, SocialConnectLink, SocialEnvironment, SocialMedia, SocialOverview, SocialPost, SocialPostAnalytics, SocialPostInput, SpeechRequest, Transcription, UsageOptions, UsagePeriod, UsageReport, VersionDiff, VersionList, VersionRestore, VibizFile, WebDesignInput, WebhookDelivery, WebhookEventType, Withdrawal } from './types.js';
|
|
2
2
|
/**
|
|
3
3
|
* An error status with no Vibiz error body: a proxy, a load balancer or the
|
|
4
4
|
* network answered instead of the API. Say so, and what to do.
|
|
@@ -1056,6 +1056,8 @@ export declare class Vibiz {
|
|
|
1056
1056
|
n?: number;
|
|
1057
1057
|
size?: string;
|
|
1058
1058
|
aspect_ratio?: "16:9" | "9:16" | "1:1";
|
|
1059
|
+
/** With a `fal/<endpoint>` model (your own fal key): raw input for that endpoint. */
|
|
1060
|
+
fal_input?: Record<string, unknown>;
|
|
1059
1061
|
};
|
|
1060
1062
|
}, opts?: {
|
|
1061
1063
|
idempotencyKey?: string;
|
|
@@ -1090,23 +1092,23 @@ export declare class Vibiz {
|
|
|
1090
1092
|
list: (opts?: {
|
|
1091
1093
|
projectId?: string;
|
|
1092
1094
|
}) => Promise<AiProviderKeyList>;
|
|
1093
|
-
get: (provider:
|
|
1095
|
+
get: (provider: AiKeyProvider, opts?: {
|
|
1094
1096
|
projectId?: string;
|
|
1095
1097
|
}) => Promise<AiProviderKey>;
|
|
1096
1098
|
/** Checked with a cheap call to the provider first; refused with the reason if it fails. */
|
|
1097
|
-
set: (provider:
|
|
1099
|
+
set: (provider: AiKeyProvider, input: AiProviderKeyInput, opts?: {
|
|
1098
1100
|
projectId?: string;
|
|
1099
1101
|
}) => Promise<AiProviderKey>;
|
|
1100
1102
|
/** Which capabilities the key serves; the rest runs on Vibiz. */
|
|
1101
|
-
update: (provider:
|
|
1103
|
+
update: (provider: AiKeyProvider, patch: {
|
|
1102
1104
|
use_for: AiProviderKey["use_for"] & {};
|
|
1103
1105
|
}, opts?: {
|
|
1104
1106
|
projectId?: string;
|
|
1105
1107
|
}) => Promise<AiProviderKey>;
|
|
1106
|
-
test: (provider:
|
|
1108
|
+
test: (provider: AiKeyProvider, opts?: {
|
|
1107
1109
|
projectId?: string;
|
|
1108
1110
|
}) => Promise<AiProviderKey>;
|
|
1109
|
-
remove: (provider:
|
|
1111
|
+
remove: (provider: AiKeyProvider, opts?: {
|
|
1110
1112
|
projectId?: string;
|
|
1111
1113
|
}) => Promise<AiProviderKey>;
|
|
1112
1114
|
};
|
package/dist/index.js
CHANGED
|
@@ -1941,7 +1941,7 @@ function formatMinor(minor, currency) {
|
|
|
1941
1941
|
}
|
|
1942
1942
|
|
|
1943
1943
|
// packages/sdk/src/one-key.ts
|
|
1944
|
-
var APP_SDK_VERSION = "0.3.
|
|
1944
|
+
var APP_SDK_VERSION = "0.3.10";
|
|
1945
1945
|
var ONE_KEY_GIVES = "database, sign-in, email and inbox, AI models, files, payments, analytics with session replays, web data, social, phone and connectors";
|
|
1946
1946
|
function oneKeyMessage(url, host) {
|
|
1947
1947
|
const where = host ?? "your host";
|
package/dist/one-key.d.ts
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* (`npm install --save-exact @vibiz/app@<this>`). A test keeps it, the skills
|
|
11
11
|
* and the docs equal to packages/app/package.json.
|
|
12
12
|
*/
|
|
13
|
-
export declare const APP_SDK_VERSION = "0.3.
|
|
13
|
+
export declare const APP_SDK_VERSION = "0.3.10";
|
|
14
14
|
/** Everything one app key reaches. */
|
|
15
15
|
export declare const ONE_KEY_GIVES = "database, sign-in, email and inbox, AI models, files, payments, analytics with session replays, web data, social, phone and connectors";
|
|
16
16
|
/**
|
package/dist/types.d.ts
CHANGED
|
@@ -1390,6 +1390,11 @@ export interface ImageRequest {
|
|
|
1390
1390
|
quality?: 'low' | 'medium' | 'high';
|
|
1391
1391
|
/** `b64_json` (default) or `url`: a Vibiz link valid for a day. */
|
|
1392
1392
|
response_format?: 'b64_json' | 'url';
|
|
1393
|
+
/**
|
|
1394
|
+
* With a `fal/<endpoint>` model, which runs only on your own fal key: raw
|
|
1395
|
+
* input for that endpoint, merged into what it receives (at most 16 KB).
|
|
1396
|
+
*/
|
|
1397
|
+
fal_input?: Record<string, unknown>;
|
|
1393
1398
|
}
|
|
1394
1399
|
export interface ImageResult {
|
|
1395
1400
|
created: number;
|
|
@@ -1500,11 +1505,13 @@ export interface AiSettings {
|
|
|
1500
1505
|
spent_today_usd: number;
|
|
1501
1506
|
}
|
|
1502
1507
|
export type AiCapabilityName = 'llm' | 'embeddings' | 'image' | 'video' | 'speech' | 'transcription';
|
|
1503
|
-
export type AiProviderKeyType = 'gemini_api_key' | 'vertex';
|
|
1508
|
+
export type AiProviderKeyType = 'gemini_api_key' | 'vertex' | 'fal_key';
|
|
1509
|
+
/** Whose keys you can add: Google (Gemini / Vertex AI) and fal (images, video, any fal/<endpoint>). */
|
|
1510
|
+
export type AiKeyProvider = 'google' | 'fal';
|
|
1504
1511
|
/** A customer key's status. Never the secret: only its last 4 characters. */
|
|
1505
1512
|
export interface AiProviderKey {
|
|
1506
1513
|
object: 'ai_provider_key';
|
|
1507
|
-
provider:
|
|
1514
|
+
provider: AiKeyProvider;
|
|
1508
1515
|
scope: 'account' | 'project';
|
|
1509
1516
|
project_id: string | null;
|
|
1510
1517
|
has_key: boolean;
|
|
@@ -1551,6 +1558,11 @@ export interface AiProviderKey {
|
|
|
1551
1558
|
status?: number;
|
|
1552
1559
|
google_status?: string;
|
|
1553
1560
|
google_reason?: string;
|
|
1561
|
+
/** A good key with something to fix (fal: the account is out of credit). */
|
|
1562
|
+
warning?: {
|
|
1563
|
+
reason: string;
|
|
1564
|
+
message: string;
|
|
1565
|
+
};
|
|
1554
1566
|
};
|
|
1555
1567
|
deleted?: boolean;
|
|
1556
1568
|
}
|
|
@@ -1558,6 +1570,12 @@ export type AiProviderKeyInput = {
|
|
|
1558
1570
|
type: 'gemini_api_key';
|
|
1559
1571
|
api_key: string;
|
|
1560
1572
|
use_for?: AiCapabilityName[];
|
|
1573
|
+
}
|
|
1574
|
+
/** A fal key (`<key id>:<secret>`, from fal.ai/dashboard/keys). */
|
|
1575
|
+
| {
|
|
1576
|
+
type: 'fal_key';
|
|
1577
|
+
api_key: string;
|
|
1578
|
+
use_for?: AiCapabilityName[];
|
|
1561
1579
|
} | {
|
|
1562
1580
|
type: 'vertex';
|
|
1563
1581
|
/** The service account key file: its JSON text or the parsed object. */
|